summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2004-11-29 06:42:02 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:06:12 -0500
commit77be33e31c11ac3b667f3019d23c2fcde1e8692f (patch)
tree677fdbbd880e20a4b3b83a889ae2a1a744d713d0
parentf11aa2329666768fc219292be3b51a646aba870a (diff)
downloadsamba-77be33e31c11ac3b667f3019d23c2fcde1e8692f.tar.gz
samba-77be33e31c11ac3b667f3019d23c2fcde1e8692f.tar.bz2
samba-77be33e31c11ac3b667f3019d23c2fcde1e8692f.zip
r3995: improved the default ACL mapping from unix perms
(This used to be commit 01e89697fe837ee76fedda149e1e2b389a7d3889)
-rw-r--r--source4/ntvfs/posix/pvfs_acl.c18
1 files changed, 11 insertions, 7 deletions
diff --git a/source4/ntvfs/posix/pvfs_acl.c b/source4/ntvfs/posix/pvfs_acl.c
index f079857821..2ff873fd78 100644
--- a/source4/ntvfs/posix/pvfs_acl.c
+++ b/source4/ntvfs/posix/pvfs_acl.c
@@ -83,15 +83,17 @@ static NTSTATUS pvfs_default_acl(struct pvfs_state *pvfs,
SA_RIGHT_FILE_READ_DATA |
SA_RIGHT_FILE_READ_EA |
SA_RIGHT_FILE_READ_ATTRIBUTES |
- SA_RIGHT_FILE_EXECUTE;
+ SA_RIGHT_FILE_EXECUTE |
+ STD_RIGHT_SYNCHRONIZE_ACCESS |
+ STD_RIGHT_READ_CONTROL_ACCESS;
}
if (mode & S_IWUSR) {
access_masks[1] |=
SA_RIGHT_FILE_WRITE_DATA |
SA_RIGHT_FILE_APPEND_DATA |
SA_RIGHT_FILE_WRITE_EA |
- SA_RIGHT_FILE_DELETE_CHILD |
- SA_RIGHT_FILE_WRITE_ATTRIBUTES;
+ SA_RIGHT_FILE_WRITE_ATTRIBUTES |
+ STD_RIGHT_DELETE_ACCESS;
}
if (mode & S_IRGRP) {
@@ -99,14 +101,15 @@ static NTSTATUS pvfs_default_acl(struct pvfs_state *pvfs,
SA_RIGHT_FILE_READ_DATA |
SA_RIGHT_FILE_READ_EA |
SA_RIGHT_FILE_READ_ATTRIBUTES |
- SA_RIGHT_FILE_EXECUTE;
+ SA_RIGHT_FILE_EXECUTE |
+ STD_RIGHT_SYNCHRONIZE_ACCESS |
+ STD_RIGHT_READ_CONTROL_ACCESS;
}
if (mode & S_IWGRP) {
access_masks[2] |=
SA_RIGHT_FILE_WRITE_DATA |
SA_RIGHT_FILE_APPEND_DATA |
SA_RIGHT_FILE_WRITE_EA |
- SA_RIGHT_FILE_DELETE_CHILD |
SA_RIGHT_FILE_WRITE_ATTRIBUTES;
}
@@ -115,14 +118,15 @@ static NTSTATUS pvfs_default_acl(struct pvfs_state *pvfs,
SA_RIGHT_FILE_READ_DATA |
SA_RIGHT_FILE_READ_EA |
SA_RIGHT_FILE_READ_ATTRIBUTES |
- SA_RIGHT_FILE_EXECUTE;
+ SA_RIGHT_FILE_EXECUTE |
+ STD_RIGHT_SYNCHRONIZE_ACCESS |
+ STD_RIGHT_READ_CONTROL_ACCESS;
}
if (mode & S_IWOTH) {
access_masks[3] |=
SA_RIGHT_FILE_WRITE_DATA |
SA_RIGHT_FILE_APPEND_DATA |
SA_RIGHT_FILE_WRITE_EA |
- SA_RIGHT_FILE_DELETE_CHILD |
SA_RIGHT_FILE_WRITE_ATTRIBUTES;
}