diff options
Diffstat (limited to 'source3/smbd')
-rw-r--r-- | source3/smbd/fake_file.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/source3/smbd/fake_file.c b/source3/smbd/fake_file.c index 81f7686726..68967fb268 100644 --- a/source3/smbd/fake_file.c +++ b/source3/smbd/fake_file.c @@ -19,6 +19,7 @@ #include "includes.h" #include "smbd/smbd.h" +#include "smbd/globals.h" #include "fake_file.h" #include "auth.h" @@ -128,6 +129,18 @@ NTSTATUS open_fake_file(struct smb_request *req, connection_struct *conn, files_struct *fsp = NULL; NTSTATUS status; + status = smbd_calculate_access_mask(conn, smb_fname, + false, /* fake files do not exist */ + access_mask, &access_mask); + if (!NT_STATUS_IS_OK(status)) { + DEBUG(10, ("open_fake_file: smbd_calculate_access_mask " + "on service[%s] file[%s] returned %s\n", + lp_servicename(SNUM(conn)), + smb_fname_str_dbg(smb_fname), + nt_errstr(status))); + return status; + } + /* access check */ if (geteuid() != sec_initial_uid()) { DEBUG(3, ("open_fake_file_shared: access_denied to " |