diff --git a/source3/modules/vfs_default.c b/source3/modules/vfs_default.c index 98188a50c34..62ad5063af0 100644 --- a/source3/modules/vfs_default.c +++ b/source3/modules/vfs_default.c @@ -1897,14 +1897,14 @@ static void vfswrap_get_dos_attributes_getxattr_done(struct tevent_req *subreq) state->as_root = true; - set_effective_capability(DAC_OVERRIDE_CAPABILITY); + become_root(); subreq = SMB_VFS_GETXATTRAT_SEND(state, state->ev, state->dir_fsp, state->smb_fname, SAMBA_XATTR_DOS_ATTRIB, sizeof(fstring)); - drop_effective_capability(DAC_OVERRIDE_CAPABILITY); + unbecome_root(); if (tevent_req_nomem(subreq, req)) { return; }