1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-22 13:34:15 +03:00

Revert "nfs4_acls.c: prefer capabilities over become_root"

This reverts commit 06e5c1e32e.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=15583
Signed-off-by: Bjoern Jacke <bjacke@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
This commit is contained in:
Björn Jacke 2024-03-25 17:04:23 +01:00 committed by Ralph Boehme
parent af7b930e2b
commit 33e88911ee

View File

@ -1201,12 +1201,12 @@ NTSTATUS smb_set_nt_acl_nfs4(vfs_handle_struct *handle, files_struct *fsp,
smbacl4_dump_nfs4acl(10, theacl);
if (set_acl_as_root) {
set_effective_capability(DAC_OVERRIDE_CAPABILITY);
become_root();
}
result = set_nfs4_native(handle, fsp, theacl);
saved_errno = errno;
if (set_acl_as_root) {
drop_effective_capability(DAC_OVERRIDE_CAPABILITY);
unbecome_root();
}
TALLOC_FREE(frame);