summaryrefslogtreecommitdiff
path: root/source4/ntvfs
diff options
context:
space:
mode:
Diffstat (limited to 'source4/ntvfs')
-rw-r--r--source4/ntvfs/posix/pvfs_open.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/source4/ntvfs/posix/pvfs_open.c b/source4/ntvfs/posix/pvfs_open.c
index 739c127b98..cfa88b6baa 100644
--- a/source4/ntvfs/posix/pvfs_open.c
+++ b/source4/ntvfs/posix/pvfs_open.c
@@ -1155,13 +1155,16 @@ NTSTATUS pvfs_open(struct ntvfs_module_context *ntvfs,
return NT_STATUS_ACCESS_DENIED;
}
+ /* what does this bit really mean?? */
if (req->ctx->protocol == PROTOCOL_SMB2 &&
- (access_mask & SEC_STD_SYNCHRONIZE)) {
+ (access_mask & SEC_STD_SYNCHRONIZE) &&
+ !(access_mask & SEC_STD_READ_CONTROL)) {
return NT_STATUS_ACCESS_DENIED;
}
if (io->ntcreatex.in.file_attr & (FILE_ATTRIBUTE_DEVICE|
- FILE_ATTRIBUTE_VOLUME)) {
+ FILE_ATTRIBUTE_VOLUME|
+ (~FILE_ATTRIBUTE_ALL_MASK))) {
return NT_STATUS_INVALID_PARAMETER;
}