From edd5a572d8f5d94511013e55744fcde48b16a3eb Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Fri, 5 Mar 2010 17:50:18 +1100 Subject: s4-pvfs: added new pvfs flag PVFS_FLAG_PERM_OVERRIDE This flag indicates that we should use root privileges to override unix permissions when the NT ACLs indicate that access should be granted Pair-Programmed-With: Andrew Bartlett --- source4/ntvfs/posix/vfs_posix.c | 2 ++ source4/ntvfs/posix/vfs_posix.h | 2 ++ 2 files changed, 4 insertions(+) (limited to 'source4/ntvfs') diff --git a/source4/ntvfs/posix/vfs_posix.c b/source4/ntvfs/posix/vfs_posix.c index 5134c0a608..f22f1d4817 100644 --- a/source4/ntvfs/posix/vfs_posix.c +++ b/source4/ntvfs/posix/vfs_posix.c @@ -58,6 +58,8 @@ static void pvfs_setup_options(struct pvfs_state *pvfs) pvfs->flags |= PVFS_FLAG_FAKE_OPLOCKS; if (share_bool_option(scfg, PVFS_AIO, false)) pvfs->flags |= PVFS_FLAG_LINUX_AIO; + if (share_bool_option(scfg, PVFS_PERM_OVERRIDE, true)) + pvfs->flags |= PVFS_FLAG_PERM_OVERRIDE; /* file perm options */ pvfs->options.create_mask = share_int_option(scfg, diff --git a/source4/ntvfs/posix/vfs_posix.h b/source4/ntvfs/posix/vfs_posix.h index 86e95327c1..70e4c90d7a 100644 --- a/source4/ntvfs/posix/vfs_posix.h +++ b/source4/ntvfs/posix/vfs_posix.h @@ -246,6 +246,7 @@ struct pvfs_search_state { #define PVFS_FLAG_XATTR_ENABLE (1<<7) #define PVFS_FLAG_FAKE_OPLOCKS (1<<8) #define PVFS_FLAG_LINUX_AIO (1<<9) +#define PVFS_FLAG_PERM_OVERRIDE (1<<10) /* forward declare some anonymous structures */ struct pvfs_dir; @@ -268,6 +269,7 @@ struct pvfs_odb_retry; #define PVFS_SEARCH_INACTIVITY "posix:searchinactivity" #define PVFS_ACL "posix:acl" #define PVFS_AIO "posix:aio" +#define PVFS_PERM_OVERRIDE "posix:permission override" #define PVFS_XATTR_DEFAULT true #define PVFS_FAKE_OPLOCKS_DEFAULT false -- cgit