From: Ralph Boehme Date: Sat, 8 May 2021 19:45:25 +0000 (+0200) Subject: smbd: drop requirement for full open for READ_CONTROL_ACCESS, WRITE_DAC_ACCESS and... X-Git-Tag: ldb-2.5.0~1042 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e71e373a07e467ff2d2328f39bd2bc285e2ba840;p=thirdparty%2Fsamba.git smbd: drop requirement for full open for READ_CONTROL_ACCESS, WRITE_DAC_ACCESS and WRITE_OWNER_ACCESS This was needed before we had pathref fsps, with pathref fsps we can do operation requiring WRITE_OWNER_ACCESS, WRITE_DAC_ACCESS and READ_CONTROL_ACCESS on the pathref fsp. BUG: https://bugzilla.samba.org/show_bug.cgi?id=14700 Signed-off-by: Ralph Boehme Reviewed-by: Jeremy Allison --- diff --git a/source3/smbd/open.c b/source3/smbd/open.c index c29662b4fd2..2427774af1f 100644 --- a/source3/smbd/open.c +++ b/source3/smbd/open.c @@ -1279,10 +1279,7 @@ static NTSTATUS open_file(files_struct *fsp, FILE_WRITE_DATA | FILE_APPEND_DATA | FILE_EXECUTE | - WRITE_DAC_ACCESS | - WRITE_OWNER_ACCESS | - SEC_FLAG_SYSTEM_SECURITY | - READ_CONTROL_ACCESS; + SEC_FLAG_SYSTEM_SECURITY; bool creating = !file_existed && (flags & O_CREAT); bool truncating = (flags & O_TRUNC); bool open_fd = false;