[SCM] Samba Shared Repository - branch v3-3-test updated - release-3-2-0pre2-4340-g630b6b7

Jeremy Allison jra at samba.org
Thu Nov 6 09:41:43 GMT 2008


The branch, v3-3-test has been updated
       via  630b6b7d28ce8e7dcce2dfa432271e9159a38f8e (commit)
      from  5b2d6d5d3615c90b5b73b4d9db69c48b40b367b2 (commit)

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-3-test


- Log -----------------------------------------------------------------
commit 630b6b7d28ce8e7dcce2dfa432271e9159a38f8e
Author: Jeremy Allison <jra at samba.org>
Date:   Thu Nov 6 01:41:15 2008 -0800

    Don't call FSET_NT_ACL on file create if there's no SD to set. Leave the default ACL in place.
    Jeremy.

-----------------------------------------------------------------------

Summary of changes:
 source/modules/vfs_acl_xattr.c |    4 ----
 source/smbd/open.c             |    7 ++++++-
 2 files changed, 6 insertions(+), 5 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source/modules/vfs_acl_xattr.c b/source/modules/vfs_acl_xattr.c
index a5fa6b0..7f32af2 100644
--- a/source/modules/vfs_acl_xattr.c
+++ b/source/modules/vfs_acl_xattr.c
@@ -528,10 +528,6 @@ static NTSTATUS fset_nt_acl_xattr(vfs_handle_struct *handle, files_struct *fsp,
 			CONST_DISCARD(struct security_descriptor *,psd));
 	}
 
-	if (!psd->owner_sid && !psd->group_sid && !(psd->type & SEC_DESC_DACL_PRESENT)) {
-		return NT_STATUS_OK;
-	}
-
 	status = SMB_VFS_NEXT_FSET_NT_ACL(handle, fsp, security_info_sent, psd);
 	if (!NT_STATUS_IS_OK(status)) {
 		return status;
diff --git a/source/smbd/open.c b/source/smbd/open.c
index adbe980..baa7b06 100644
--- a/source/smbd/open.c
+++ b/source/smbd/open.c
@@ -2921,7 +2921,12 @@ NTSTATUS create_file_unixpath(connection_struct *conn,
 		security_acl_map_generic(sd->dacl, &file_generic_mapping);
 		security_acl_map_generic(sd->sacl, &file_generic_mapping);
 
-		status = SMB_VFS_FSET_NT_ACL(fsp, sec_info_sent, sd);
+		if (sec_info_sent & (OWNER_SECURITY_INFORMATION|
+					GROUP_SECURITY_INFORMATION|
+					DACL_SECURITY_INFORMATION|
+					SACL_SECURITY_INFORMATION)) {
+			status = SMB_VFS_FSET_NT_ACL(fsp, sec_info_sent, sd);
+		}
 
 		fsp->access_mask = saved_access_mask;
 


-- 
Samba Shared Repository


More information about the samba-cvs mailing list