Start moving us closer to passing S4 RAW-ACL test using the vfs_acl_xattr module...
[sfrench/samba-autobuild/.git] / source3 / smbd / open.c
index d858fb969f97fb7ad40de80ed3f7eaaaf913a898..15645250054d927e9e5b9a5004351d46ff941fbd 100644 (file)
@@ -1206,6 +1206,15 @@ NTSTATUS open_file_ntcreate(connection_struct *conn,
                   create_disposition, create_options, unx_mode,
                   oplock_request));
 
+       if ((access_mask & FILE_READ_DATA)||(access_mask & FILE_WRITE_DATA)) {
+               DEBUG(10, ("open_file_ntcreate: adding FILE_READ_ATTRIBUTES "
+                       "to requested access_mask 0x%x, new mask 0x%x",
+                       access_mask,
+                       access_mask | FILE_READ_ATTRIBUTES ));
+
+               access_mask |= FILE_READ_ATTRIBUTES;
+       }
+
        if ((req == NULL) && ((oplock_request & INTERNAL_OPEN_ONLY) == 0)) {
                DEBUG(0, ("No smb request but not an internal only open!\n"));
                return NT_STATUS_INTERNAL_ERROR;