From c983424abb431aef56d09ca41bbb3359e286bfe9 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Mon, 7 Oct 2002 18:06:17 +0000 Subject: Fix from Andreas Gruenbacher to prevent ACL set on read-only share. Jeremy. (This used to be commit 80d30dbfec03d1d1e82c9e177ff66aa44b4ea993) --- source3/smbd/posix_acls.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source3/smbd') diff --git a/source3/smbd/posix_acls.c b/source3/smbd/posix_acls.c index e6ae1c7d79..6b1b62417a 100644 --- a/source3/smbd/posix_acls.c +++ b/source3/smbd/posix_acls.c @@ -2124,6 +2124,11 @@ BOOL set_nt_acl(files_struct *fsp, uint32 security_info_sent, SEC_DESC *psd) DEBUG(10,("set_nt_acl: called for file %s\n", fsp->fsp_name )); + if (!CAN_WRITE(conn)) { + DEBUG(10,("set acl rejected on read-only share\n")); + return False; + } + /* * Get the current state of the file. */ -- cgit