The Samba-Bugzilla – Attachment 14090 Details for
Bug 13358
Samba fails DELETE_ON_CLOSE open but leaves newly created file
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Here's the naive fix as a patch.
look (text/plain), 798 bytes, created by
Jeremy Allison
on 2018-03-27 19:24:11 UTC
(
hide
)
Description:
Here's the naive fix as a patch.
Filename:
MIME Type:
Creator:
Jeremy Allison
Created:
2018-03-27 19:24:11 UTC
Size:
798 bytes
patch
obsolete
>diff --git a/source3/smbd/open.c b/source3/smbd/open.c >index be9e601bb15..baf6619afdf 100644 >--- a/source3/smbd/open.c >+++ b/source3/smbd/open.c >@@ -3269,6 +3269,21 @@ static NTSTATUS open_file_ntcreate(connection_struct *conn, > return NT_STATUS_ACCESS_DENIED; > } > >+ /* >+ * Ensure we can't create a file with delete on close >+ * if we don't have delete access. >+ */ >+ if (create_options & FILE_DELETE_ON_CLOSE) { >+ if ((access_mask & DELETE_ACCESS) == 0) { >+ DBG_INFO("DELETE_ON_CLOSE reqested for " >+ "file %s but no DELETE access\n", >+ smb_fname_str_dbg(smb_fname)); >+ errno = EACCES; >+ return NT_STATUS_ACCESS_DENIED; >+ } >+ } >+ >+ > fsp->file_id = vfs_file_id_from_sbuf(conn, &smb_fname->st); > fsp->share_access = share_access; > fsp->fh->private_options = private_flags;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Flags:
sfrench
:
review+
Actions:
View
Attachments on
bug 13358
:
14086
|
14088
|
14089
|
14090
|
14092
|
14096
|
14097