diff options
| author | Ralph Boehme <slow@samba.org> | 2026-06-20 09:12:42 +0200 |
|---|---|---|
| committer | Steve French <stfrench@microsoft.com> | 2026-06-24 10:33:41 -0500 |
| commit | 4939889c985da68936090cc013e58c28b7bff34f (patch) | |
| tree | b9393d980c6493e9085720111c21a6b7b47810fc /tools/perf/scripts/python/stackcollapse.py | |
| parent | a540a64c4801fe02e452ee37e961018106418260 (diff) | |
smb/client: fix security flag calculation when setting security descriptors
In id_mode_to_cifs_acl(), aclflag was initialized to CIFS_ACL_DACL by default.
This forced the client to request setting the DACL even when only an ownership
(chown) or group (chgrp) change was being performed.
Let build_sec_desc() do the proper flag calculation by initializing aclflag
to 0. build_sec_desc() sets the appropriate bits (CIFS_ACL_OWNER, CIFS_ACL_GROUP,
or CIFS_ACL_DACL) depending on what actually changed. During ownership transfer,
CIFS_ACL_DACL is only set if replace_sids_and_copy_aces() actually replaces the
SIDs inside any of the DACL's ACEs.
If build_sec_desc() results in aclflag being 0 (meaning no changes were mapped),
exit early to avoid sending an empty security descriptor update to the server.
Signed-off-by: Ralph Boehme <slow@samba.org>
Signed-off-by: Steve French <stfrench@microsoft.com>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions
