]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3:modules fix Bug 8330 NFSv4 ACL merging logic is broken
authorChristian Ambach <ambi@samba.org>
Wed, 27 Jul 2011 12:46:00 +0000 (14:46 +0200)
committerKarolin Seeger <kseeger@samba.org>
Tue, 9 Aug 2011 11:05:07 +0000 (13:05 +0200)
we should not merge ACEs with different flags (e.g. CI/OI/I/)
Otherwise ACLs get wrong entries and thus wrong semantics

Example:
ACL:BUILTIN\Users:ALLOWED/0x0/FULL
ACL:BUILTIN\Users:ALLOWED/I/READ
got merged to
ACL:BUILTIN\Users:ALLOWED/I/FULL

This is not the same and also leads to wrong displays
in the Windows ACL dialog

Autobuild-User: Christian Ambach <ambi@samba.org>
Autobuild-Date: Wed Jul 27 16:03:51 CEST 2011 on sn-devel-104

source3/modules/nfs4_acls.c

index be8a505c4d5163e837690b1e1c2d40d0a65fa017..05047797b769dedcd56094c87cb3b9f81f6d79b1 100644 (file)
@@ -516,8 +516,7 @@ static SMB_ACE4PROP_T *smbacl4_find_equal_special(
 
                if (ace->flags == aceNew->flags &&
                        ace->aceType==aceNew->aceType &&
-                       ((ace->aceFlags&SMB_ACE4_INHERIT_ONLY_ACE)==
-                        (aceNew->aceFlags&SMB_ACE4_INHERIT_ONLY_ACE)) &&
+                       ace->aceFlags==aceNew->aceFlags &&
                        (ace->aceFlags&SMB_ACE4_IDENTIFIER_GROUP)==
                        (aceNew->aceFlags&SMB_ACE4_IDENTIFIER_GROUP)
                ) {