summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorGael Blivet <gael.blivet@gmail.com>2026-07-17 09:15:04 +0200
committerNamjae Jeon <linkinjeon@kernel.org>2026-08-17 15:00:49 +0900
commit08f41323f549b1ad9ad2e67e7b5c5ac312c1cb1a (patch)
tree1aff0887fc9d0254bfeb3e7f7126c47e416067e0 /tools/perf/scripts/python
parenteebdd3f1157e35a50df5ff2d3d9a305901df3254 (diff)
ksmbd: fix maximal access leak when object has no NT ACL
smb2_open()'s maximal-access handling sets maximal_access to the FILE_MAXIMAL_ACCESS_LE request sentinel, then calls smb_check_perm_dacl() to compute the real access mask from the object's DACL. smb_check_perm_dacl() returns success without touching *pdaccess when the object has no stored NT ACL xattr (ksmbd_vfs_get_sd_xattr() fails, taking an early goto err_out with rc still 0). This leaves maximal_access holding the raw FILE_MAXIMAL_ACCESS_LE sentinel instead of a real access mask. Observed live: a freshly-created share root shows macOS's "no entry" (prohibited-access) badge on connect, even though POSIX permissions clearly allow access -- macOS requests maximal access via the MxAc create context on every share-root open, not via DesiredAccess, so it trusts the leaked sentinel verbatim instead of falling through to the correct POSIX-based path. Fall back to ksmbd_vfs_query_maximal_access() -- the same POSIX-based computation already used for the DesiredAccess-requested-maximal-access case below -- whenever the sentinel comes back unmodified. Signed-off-by: Gael Blivet <gael.blivet@gmail.com> Assisted-by: Claude:claude-sonnet-5 Signed-off-by: Namjae Jeon <linkinjeon@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions