diff options
author | Jeremy Allison <jra@samba.org> | 2001-09-07 20:04:51 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2001-09-07 20:04:51 +0000 |
commit | cc728c9226fa535f6a5f8ad3b2852250f87715eb (patch) | |
tree | b6465ac5851349918982d6d350b73790b99d3170 | |
parent | ca0406105550cd527ad6bb67e73efe3f42383ec6 (diff) | |
download | samba-cc728c9226fa535f6a5f8ad3b2852250f87715eb.tar.gz samba-cc728c9226fa535f6a5f8ad3b2852250f87715eb.tar.xz samba-cc728c9226fa535f6a5f8ad3b2852250f87715eb.zip |
If no owners sent, don't fail the ACL set, just use the original owners.
Jeremy.
-rw-r--r-- | source/smbd/posix_acls.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/source/smbd/posix_acls.c b/source/smbd/posix_acls.c index 357b9fe2ee9..501dcab7105 100644 --- a/source/smbd/posix_acls.c +++ b/source/smbd/posix_acls.c @@ -419,7 +419,7 @@ static BOOL unpack_nt_owners(SMB_STRUCT_STAT *psbuf, uid_t *puser, gid_t *pgrp, if(security_info_sent == 0) { DEBUG(0,("unpack_nt_owners: no security info sent !\n")); - return False; + return True; } /* @@ -438,8 +438,10 @@ static BOOL unpack_nt_owners(SMB_STRUCT_STAT *psbuf, uid_t *puser, gid_t *pgrp, if (security_info_sent & OWNER_SECURITY_INFORMATION) { sid_copy(&owner_sid, psd->owner_sid); - if (!sid_to_uid( &owner_sid, puser, &sid_type)) + if (!sid_to_uid( &owner_sid, puser, &sid_type)) { DEBUG(3,("unpack_nt_owners: unable to validate owner sid.\n")); + return False; + } } /* @@ -449,8 +451,10 @@ static BOOL unpack_nt_owners(SMB_STRUCT_STAT *psbuf, uid_t *puser, gid_t *pgrp, if (security_info_sent & GROUP_SECURITY_INFORMATION) { sid_copy(&grp_sid, psd->grp_sid); - if (!sid_to_gid( &grp_sid, pgrp, &sid_type)) + if (!sid_to_gid( &grp_sid, pgrp, &sid_type)) { DEBUG(3,("unpack_nt_owners: unable to validate group sid.\n")); + return False; + } } DEBUG(5,("unpack_nt_owners: owner_sids validated.\n")); |