Yay ! Remove a VFS entry. Removed the set_nt_acl() call,
authorJeremy Allison <jra@samba.org>
Fri, 9 May 2008 01:09:07 +0000 (18:09 -0700)
committerJeremy Allison <jra@samba.org>
Fri, 9 May 2008 01:09:07 +0000 (18:09 -0700)
this can only be done via fset_nt_acl() using an open
file/directory handle. I'd like to do the same with
get_nt_acl() but am concerned about efficiency
problems with "hide unreadable/hide unwritable" when
doing a directory listing (this would mean opening
every file in the dir on list).
Moving closer to rationalizing the ACL model and
maybe moving the POSIX calls into a posix_acl VFS
module rather than having them as first class citizens
of the VFS.
Jeremy.
(This used to be commit f487f742cb903a06fbf2be006ddc9ce9063339ed)

18 files changed:
examples/VFS/skel_opaque.c
examples/VFS/skel_transparent.c
source3/include/smbprofile.h
source3/include/vfs.h
source3/include/vfs_macros.h
source3/modules/vfs_afsacl.c
source3/modules/vfs_aixacl2.c
source3/modules/vfs_cap.c
source3/modules/vfs_catia.c
source3/modules/vfs_default.c
source3/modules/vfs_full_audit.c
source3/modules/vfs_gpfs.c
source3/modules/vfs_shadow_copy2.c
source3/modules/vfs_zfsacl.c
source3/profile/profile.c
source3/rpc_server/srv_srvsvc_nt.c
source3/smbd/nttrans.c
source3/utils/status_profile.c

index eb49f35c0428b61179ebd5f262a1fb99be99062e..bac035a821607e65604279ba582478f4f1c03ed3 100644 (file)
@@ -321,13 +321,6 @@ static NTSTATUS skel_fset_nt_acl(vfs_handle_struct *handle, files_struct *fsp,
        return NT_STATUS_NOT_IMPLEMENTED;
 }
 
-static NTSTATUS skel_set_nt_acl(vfs_handle_struct *handle, files_struct *fsp, const
-       char *name, uint32 security_info_sent, SEC_DESC *psd)
-{
-       errno = ENOSYS;
-       return NT_STATUS_NOT_IMPLEMENTED;
-}
-
 static int skel_chmod_acl(vfs_handle_struct *handle,  const char *name, mode_t mode)
 {
        errno = ENOSYS;
@@ -662,7 +655,6 @@ static vfs_op_tuple skel_op_tuples[] = {
        {SMB_VFS_OP(skel_fget_nt_acl),                  SMB_VFS_OP_FGET_NT_ACL,         SMB_VFS_LAYER_OPAQUE},
        {SMB_VFS_OP(skel_get_nt_acl),                   SMB_VFS_OP_GET_NT_ACL,          SMB_VFS_LAYER_OPAQUE},
        {SMB_VFS_OP(skel_fset_nt_acl),                  SMB_VFS_OP_FSET_NT_ACL,         SMB_VFS_LAYER_OPAQUE},
-       {SMB_VFS_OP(skel_set_nt_acl),                   SMB_VFS_OP_SET_NT_ACL,          SMB_VFS_LAYER_OPAQUE},
 
        /* POSIX ACL operations */
 
index 7102d4d4db123108c9d44ee74fbfab69c7efb0fc..ea8530d855effd1ba701a5e749dfd93f338f50a9 100644 (file)
@@ -307,12 +307,6 @@ static NTSTATUS skel_fset_nt_acl(vfs_handle_struct *handle, files_struct *fsp,
        return SMB_VFS_NEXT_FSET_NT_ACL(handle, fsp, security_info_sent, psd);
 }
 
-static NTSTATUS skel_set_nt_acl(vfs_handle_struct *handle, files_struct *fsp,
-       const char *name, uint32 security_info_sent, SEC_DESC *psd)
-{
-       return SMB_VFS_NEXT_SET_NT_ACL(handle, fsp, name, security_info_sent, psd);
-}
-
 static int skel_chmod_acl(vfs_handle_struct *handle,  const char *name, mode_t mode)
 {
        /* If the underlying VFS doesn't have ACL support... */
@@ -624,7 +618,6 @@ static vfs_op_tuple skel_op_tuples[] = {
        {SMB_VFS_OP(skel_fget_nt_acl),                  SMB_VFS_OP_FGET_NT_ACL,         SMB_VFS_LAYER_TRANSPARENT},
        {SMB_VFS_OP(skel_get_nt_acl),                   SMB_VFS_OP_GET_NT_ACL,          SMB_VFS_LAYER_TRANSPARENT},
        {SMB_VFS_OP(skel_fset_nt_acl),                  SMB_VFS_OP_FSET_NT_ACL,         SMB_VFS_LAYER_TRANSPARENT},
-       {SMB_VFS_OP(skel_set_nt_acl),                   SMB_VFS_OP_SET_NT_ACL,          SMB_VFS_LAYER_TRANSPARENT},
 
        /* POSIX ACL operations */
 
index 864f2bf90f8d6db7aec11914f3bcf70341c6a941..f58a6452bfe08606bd75c8ce5a0d72be7ba0d143 100644 (file)
@@ -631,10 +631,6 @@ enum profile_stats_values
 #define fget_nt_acl_count __profile_stats_value(PR_VALUE_FGET_NT_ACL, count)
 #define fget_nt_acl_time __profile_stats_value(PR_VALUE_FGET_NT_ACL, time)
 
-       PR_VALUE_SET_NT_ACL,
-#define set_nt_acl_count __profile_stats_value(PR_VALUE_SET_NT_ACL, count)
-#define set_nt_acl_time __profile_stats_value(PR_VALUE_SET_NT_ACL, time)
-
        PR_VALUE_FSET_NT_ACL,
 #define fset_nt_acl_count __profile_stats_value(PR_VALUE_FSET_NT_ACL, count)
 #define fset_nt_acl_time __profile_stats_value(PR_VALUE_FSET_NT_ACL, time)
index c8397164bc3e7cd47515b3ac26288b49cc35ff20..7f285b7770d29b529868731008598d27fea30dc7 100644 (file)
 /* Leave at 22 - not yet released. Additional change: add operations for offline files -- ab */
 /* Leave at 22 - not yet released. Add the streaminfo call. -- jpeach, vl */
 /* Leave at 22 - not yet released. Remove parameter fd from close_fn. - obnox */
+/* Changed to version 23 - remove set_nt_acl call. This can only be done via an
+   open handle. JRA. */
 
-#define SMB_VFS_INTERFACE_VERSION 22
+#define SMB_VFS_INTERFACE_VERSION 23
 
 
 /* to bug old modules which are trying to compile with the old functions */
@@ -208,7 +210,6 @@ typedef enum _vfs_op_type {
        SMB_VFS_OP_FGET_NT_ACL,
        SMB_VFS_OP_GET_NT_ACL,
        SMB_VFS_OP_FSET_NT_ACL,
-       SMB_VFS_OP_SET_NT_ACL,
 
        /* POSIX ACL operations. */
 
@@ -365,11 +366,6 @@ struct vfs_ops {
                                        struct files_struct *fsp,
                                        uint32 security_info_sent,
                                        struct security_descriptor *psd);
-               NTSTATUS (*set_nt_acl)(struct vfs_handle_struct *handle,
-                                      struct files_struct *fsp,
-                                      const char *name,
-                                      uint32 security_info_sent,
-                                      struct security_descriptor *psd);
 
                /* POSIX ACL operations. */
 
@@ -496,7 +492,6 @@ struct vfs_ops {
                struct vfs_handle_struct *fget_nt_acl;
                struct vfs_handle_struct *get_nt_acl;
                struct vfs_handle_struct *fset_nt_acl;
-               struct vfs_handle_struct *set_nt_acl;
 
                /* POSIX ACL operations. */
 
index f0a9809ecc6740088a6b179166c6b78019016a12..bb3aeba77b4e6260c1e679da92fb8d62734fb2e0 100644 (file)
@@ -89,7 +89,6 @@
 #define SMB_VFS_FGET_NT_ACL(fsp, security_info, ppdesc) ((fsp)->conn->vfs.ops.fget_nt_acl((fsp)->conn->vfs.handles.fget_nt_acl, (fsp), (security_info), (ppdesc)))
 #define SMB_VFS_GET_NT_ACL(conn, name, security_info, ppdesc) ((conn)->vfs.ops.get_nt_acl((conn)->vfs.handles.get_nt_acl, (name), (security_info), (ppdesc)))
 #define SMB_VFS_FSET_NT_ACL(fsp, security_info_sent, psd) ((fsp)->conn->vfs.ops.fset_nt_acl((fsp)->conn->vfs.handles.fset_nt_acl, (fsp), (security_info_sent), (psd)))
-#define SMB_VFS_SET_NT_ACL(fsp, name, security_info_sent, psd) ((fsp)->conn->vfs.ops.set_nt_acl((fsp)->conn->vfs.handles.set_nt_acl, (fsp), (name), (security_info_sent), (psd)))
 
 /* POSIX ACL operations. */
 #define SMB_VFS_CHMOD_ACL(conn, name, mode) ((conn)->vfs.ops.chmod_acl((conn)->vfs.handles.chmod_acl, (name), (mode)))
 #define SMB_VFS_OPAQUE_FGET_NT_ACL(fsp, security_info, ppdesc) ((fsp)->conn->vfs_opaque.ops.fget_nt_acl((fsp)->conn->vfs_opaque.handles.fget_nt_acl, (fsp), (security_info), (ppdesc)))
 #define SMB_VFS_OPAQUE_GET_NT_ACL(conn, name, security_info, ppdesc) ((conn)->vfs_opaque.ops.get_nt_acl((conn)->vfs_opaque.handles.get_nt_acl, (name), (security_info), (ppdesc)))
 #define SMB_VFS_OPAQUE_FSET_NT_ACL(fsp, security_info_sent, psd) ((fsp)->conn->vfs_opaque.ops.fset_nt_acl((fsp)->conn->vfs_opaque.handles.fset_nt_acl, (fsp), (security_info_sent), (psd)))
-#define SMB_VFS_OPAQUE_SET_NT_ACL(fsp, name, security_info_sent, psd) ((fsp)->conn->vfs_opaque.ops.set_nt_acl((fsp)->conn->vfs_opaque.handles.set_nt_acl, (fsp), (name), (security_info_sent), (psd)))
 
 /* POSIX ACL operations. */
 #define SMB_VFS_OPAQUE_CHMOD_ACL(conn, name, mode) ((conn)->vfs_opaque.ops.chmod_acl((conn)->vfs_opaque.handles.chmod_acl, (name), (mode)))
 #define SMB_VFS_NEXT_FGET_NT_ACL(handle, fsp, security_info, ppdesc) ((handle)->vfs_next.ops.fget_nt_acl((handle)->vfs_next.handles.fget_nt_acl, (fsp), (security_info), (ppdesc)))
 #define SMB_VFS_NEXT_GET_NT_ACL(handle, name, security_info, ppdesc) ((handle)->vfs_next.ops.get_nt_acl((handle)->vfs_next.handles.get_nt_acl, (name), (security_info), (ppdesc)))
 #define SMB_VFS_NEXT_FSET_NT_ACL(handle, fsp, security_info_sent, psd) ((handle)->vfs_next.ops.fset_nt_acl((handle)->vfs_next.handles.fset_nt_acl, (fsp), (security_info_sent), (psd)))
-#define SMB_VFS_NEXT_SET_NT_ACL(handle, fsp, name, security_info_sent, psd) ((handle)->vfs_next.ops.set_nt_acl((handle)->vfs_next.handles.set_nt_acl, (fsp), (name), (security_info_sent), (psd)))
 
 /* POSIX ACL operations. */
 #define SMB_VFS_NEXT_CHMOD_ACL(handle, name, mode) ((handle)->vfs_next.ops.chmod_acl((handle)->vfs_next.handles.chmod_acl, (name), (mode)))
index e35bfabb8c7a8df88b33c4d152c814989b42eabc..9409f3fa2039c18d7a5ae54c1357d99fa636e951 100644 (file)
@@ -1045,14 +1045,6 @@ NTSTATUS afsacl_fset_nt_acl(vfs_handle_struct *handle,
        return afs_set_nt_acl(handle, fsp, security_info_sent, psd);
 }
 
-NTSTATUS afsacl_set_nt_acl(vfs_handle_struct *handle,
-                      files_struct *fsp,
-                      const char *name, uint32 security_info_sent,
-                      SEC_DESC *psd)
-{
-       return afs_set_nt_acl(handle, fsp, security_info_sent, psd);
-}
-
 static int afsacl_connect(vfs_handle_struct *handle, 
                          const char *service, 
                          const char *user)
@@ -1078,8 +1070,6 @@ static vfs_op_tuple afsacl_ops[] = {
         SMB_VFS_LAYER_TRANSPARENT},
        {SMB_VFS_OP(afsacl_fset_nt_acl), SMB_VFS_OP_FSET_NT_ACL,
         SMB_VFS_LAYER_TRANSPARENT},
-       {SMB_VFS_OP(afsacl_set_nt_acl), SMB_VFS_OP_SET_NT_ACL,
-        SMB_VFS_LAYER_TRANSPARENT},
        {SMB_VFS_OP(NULL), SMB_VFS_OP_NOOP, SMB_VFS_LAYER_NOOP}
 };
 
index 996adbbdfe3b2c185776b7ad1da5a5987fc9ce6e..62675ae631e1b13eb67cea0f74e0036bfcd24735 100644 (file)
@@ -403,11 +403,6 @@ NTSTATUS aixjfs2_fset_nt_acl(vfs_handle_struct *handle, files_struct *fsp, uint3
        return aixjfs2_set_nt_acl_common(fsp, security_info_sent, psd);
 }
 
-NTSTATUS aixjfs2_set_nt_acl(vfs_handle_struct *handle, files_struct *fsp, const char *name, uint32 security_info_sent, SEC_DESC *psd)
-{
-       return aixjfs2_set_nt_acl_common(fsp, security_info_sent, psd);
-}
-
 int aixjfs2_sys_acl_set_file(vfs_handle_struct *handle,
                              const char *name,
                              SMB_ACL_TYPE_T type,
@@ -509,10 +504,6 @@ static vfs_op_tuple aixjfs2_ops[] =
        SMB_VFS_OP_FSET_NT_ACL,
        SMB_VFS_LAYER_TRANSPARENT},
 
-       {SMB_VFS_OP(aixjfs2_set_nt_acl),
-       SMB_VFS_OP_SET_NT_ACL,
-       SMB_VFS_LAYER_TRANSPARENT},
-
        {SMB_VFS_OP(aixjfs2_sys_acl_get_file),
        SMB_VFS_OP_SYS_ACL_GET_FILE,
        SMB_VFS_LAYER_TRANSPARENT},
index 2f2d6a718264aca27aacccf7f173125663a17e53..79537367d69c5b728d8623f431379d1a9888afac 100644 (file)
@@ -278,17 +278,6 @@ static char *cap_realpath(vfs_handle_struct *handle, const char *path, char *res
        return SMB_VFS_NEXT_REALPATH(handle, path, resolved_path);
 }
 
-static NTSTATUS cap_set_nt_acl(vfs_handle_struct *handle, files_struct *fsp, const char *path, uint32 security_info_sent, struct security_descriptor *psd)
-{
-       char *cappath = capencode(talloc_tos(), path);
-
-       if (!cappath) {
-               errno = ENOMEM;
-               return NT_STATUS_NO_MEMORY;
-       }
-       return SMB_VFS_NEXT_SET_NT_ACL(handle, fsp, cappath, security_info_sent, psd);
-}
-
 static int cap_chmod_acl(vfs_handle_struct *handle, const char *path, mode_t mode)
 {
        char *cappath = capencode(talloc_tos(), path);
@@ -499,10 +488,6 @@ static vfs_op_tuple cap_op_tuples[] = {
        {SMB_VFS_OP(cap_mknod),                 SMB_VFS_OP_MKNOD,               SMB_VFS_LAYER_TRANSPARENT},
        {SMB_VFS_OP(cap_realpath),                      SMB_VFS_OP_REALPATH,            SMB_VFS_LAYER_TRANSPARENT},
 
-       /* NT File ACL operations */
-
-       {SMB_VFS_OP(cap_set_nt_acl),                    SMB_VFS_OP_SET_NT_ACL,          SMB_VFS_LAYER_TRANSPARENT},
-
        /* POSIX ACL operations */
 
        {SMB_VFS_OP(cap_chmod_acl),                     SMB_VFS_OP_CHMOD_ACL,           SMB_VFS_LAYER_TRANSPARENT},
index ab48c963ec4fdc9122ac9a5669993875f73a8eb6..8b56be6ceac183224fc8fe051a39f32a358fb034 100644 (file)
@@ -293,14 +293,6 @@ static NTSTATUS catia_get_nt_acl(vfs_handle_struct *handle, files_struct *fsp,
         return SMB_VFS_NEXT_GET_NT_ACL(handle, name, security_info, ppdesc);
 }
 
-static NTSTATUS catia_set_nt_acl(vfs_handle_struct *handle, files_struct *fsp,
-                            const char *name, uint32 security_info_sent,
-                            struct security_descriptor *psd)
-{
-        return SMB_VFS_NEXT_SET_NT_ACL(handle, fsp, name, security_info_sent,
-                                      psd);
-}
-
 static int catia_chmod_acl(vfs_handle_struct *handle,
                           const char *name, mode_t mode)
 {
@@ -362,8 +354,6 @@ SMB_VFS_LAYER_TRANSPARENT},
 
         {SMB_VFS_OP(catia_get_nt_acl), SMB_VFS_OP_GET_NT_ACL,
 SMB_VFS_LAYER_TRANSPARENT},
-        {SMB_VFS_OP(catia_set_nt_acl), SMB_VFS_OP_SET_NT_ACL,
-SMB_VFS_LAYER_TRANSPARENT},
 
         /* POSIX ACL operations */
 
index de801a20414263e1f01b66a6a49ba70552153cb2..6ee677e3765214bb74c94180a09f14d0dbee4268 100644 (file)
@@ -1042,16 +1042,6 @@ static NTSTATUS vfswrap_fset_nt_acl(vfs_handle_struct *handle, files_struct *fsp
        return result;
 }
 
-static NTSTATUS vfswrap_set_nt_acl(vfs_handle_struct *handle, files_struct *fsp, const char *name, uint32 security_info_sent, SEC_DESC *psd)
-{
-       NTSTATUS result;
-
-       START_PROFILE(set_nt_acl);
-       result = set_nt_acl(fsp, security_info_sent, psd);
-       END_PROFILE(set_nt_acl);
-       return result;
-}
-
 static int vfswrap_chmod_acl(vfs_handle_struct *handle,  const char *name, mode_t mode)
 {
 #ifdef HAVE_NO_ACL
@@ -1446,8 +1436,6 @@ static vfs_op_tuple vfs_default_ops[] = {
         SMB_VFS_LAYER_OPAQUE},
        {SMB_VFS_OP(vfswrap_fset_nt_acl),       SMB_VFS_OP_FSET_NT_ACL,
         SMB_VFS_LAYER_OPAQUE},
-       {SMB_VFS_OP(vfswrap_set_nt_acl),        SMB_VFS_OP_SET_NT_ACL,
-        SMB_VFS_LAYER_OPAQUE},
 
        /* POSIX ACL operations. */
 
index 2f8098de9b60aaceeb2105ec3ffa08b84cac4112..19a1d02de47996e8821e5aab30b15a6489e57028 100644 (file)
@@ -199,9 +199,6 @@ static NTSTATUS smb_full_audit_get_nt_acl(vfs_handle_struct *handle, files_struc
 static NTSTATUS smb_full_audit_fset_nt_acl(vfs_handle_struct *handle, files_struct *fsp,
                              uint32 security_info_sent,
                              SEC_DESC *psd);
-static NTSTATUS smb_full_audit_set_nt_acl(vfs_handle_struct *handle, files_struct *fsp,
-                            const char *name, uint32 security_info_sent,
-                            SEC_DESC *psd);
 static int smb_full_audit_chmod_acl(vfs_handle_struct *handle,
                           const char *path, mode_t mode);
 static int smb_full_audit_fchmod_acl(vfs_handle_struct *handle, files_struct *fsp,
@@ -431,8 +428,6 @@ static vfs_op_tuple audit_op_tuples[] = {
         SMB_VFS_LAYER_LOGGER},
        {SMB_VFS_OP(smb_full_audit_fset_nt_acl),        SMB_VFS_OP_FSET_NT_ACL,
         SMB_VFS_LAYER_LOGGER},
-       {SMB_VFS_OP(smb_full_audit_set_nt_acl), SMB_VFS_OP_SET_NT_ACL,
-        SMB_VFS_LAYER_LOGGER},
 
        /* POSIX ACL operations. */
 
@@ -593,7 +588,6 @@ static struct {
        { SMB_VFS_OP_FGET_NT_ACL,       "fget_nt_acl" },
        { SMB_VFS_OP_GET_NT_ACL,        "get_nt_acl" },
        { SMB_VFS_OP_FSET_NT_ACL,       "fset_nt_acl" },
-       { SMB_VFS_OP_SET_NT_ACL,        "set_nt_acl" },
        { SMB_VFS_OP_CHMOD_ACL, "chmod_acl" },
        { SMB_VFS_OP_FCHMOD_ACL,        "fchmod_acl" },
        { SMB_VFS_OP_SYS_ACL_GET_ENTRY, "sys_acl_get_entry" },
@@ -1572,20 +1566,6 @@ static NTSTATUS smb_full_audit_fset_nt_acl(vfs_handle_struct *handle, files_stru
        return result;
 }
 
-static NTSTATUS smb_full_audit_set_nt_acl(vfs_handle_struct *handle, files_struct *fsp,
-                            const char *name, uint32 security_info_sent,
-                            SEC_DESC *psd)
-{
-       NTSTATUS result;
-
-       result = SMB_VFS_NEXT_SET_NT_ACL(handle, fsp, name, security_info_sent,
-                                        psd);
-
-       do_log(SMB_VFS_OP_SET_NT_ACL, NT_STATUS_IS_OK(result), handle, "%s", fsp->fsp_name);
-
-       return result;
-}
-
 static int smb_full_audit_chmod_acl(vfs_handle_struct *handle,
                           const char *path, mode_t mode)
 {
index d10906dfb1e07da32a85d06f92dab0d2f322ff05..39d2bb6c38c3e41c73daef549bc6659ecbde3390 100644 (file)
@@ -391,11 +391,6 @@ static NTSTATUS gpfsacl_fset_nt_acl(vfs_handle_struct *handle, files_struct *fsp
        return gpfsacl_set_nt_acl_internal(fsp, security_info_sent, psd);
 }
 
-static NTSTATUS gpfsacl_set_nt_acl(vfs_handle_struct *handle, files_struct *fsp, char *name, uint32 security_info_sent, SEC_DESC *psd)
-{
-       return gpfsacl_set_nt_acl_internal(fsp, security_info_sent, psd);
-}
-
 static SMB_ACL_T gpfs2smb_acl(const struct gpfs_acl *pacl)
 {
        SMB_ACL_T result;
@@ -839,10 +834,6 @@ static vfs_op_tuple gpfs_op_tuples[] = {
          SMB_VFS_OP_FSET_NT_ACL,
          SMB_VFS_LAYER_TRANSPARENT },
        
-        { SMB_VFS_OP(gpfsacl_set_nt_acl), 
-         SMB_VFS_OP_SET_NT_ACL,
-         SMB_VFS_LAYER_TRANSPARENT },
-       
         { SMB_VFS_OP(gpfsacl_sys_acl_get_file), 
          SMB_VFS_OP_SYS_ACL_GET_FILE,
          SMB_VFS_LAYER_TRANSPARENT },
index ddbc5aab1819a927cadc48201a94a9e9efcf57b2..c95600b642f34bd039e2455cc3239395eca1037a 100644 (file)
@@ -423,13 +423,6 @@ static NTSTATUS shadow_copy2_get_nt_acl(vfs_handle_struct *handle,
         SHADOW2_NTSTATUS_NEXT(GET_NT_ACL, (handle, name, security_info, ppdesc), NT_STATUS_ACCESS_DENIED);
 }
 
-static NTSTATUS shadow_copy2_set_nt_acl(vfs_handle_struct *handle, files_struct *fsp,
-                            const char *fname, uint32 security_info_sent,
-                            struct security_descriptor *psd)
-{
-        SHADOW2_NTSTATUS_NEXT(SET_NT_ACL, (handle, fsp, name, security_info_sent, psd), NT_STATUS_ACCESS_DENIED);
-}
-
 static int shadow_copy2_mkdir(vfs_handle_struct *handle,  const char *fname, mode_t mode)
 {
         SHADOW2_NEXT(MKDIR, (handle, name, mode), int, -1);
@@ -601,7 +594,6 @@ static vfs_op_tuple shadow_copy2_ops[] = {
 
         /* NT File ACL operations */
         {SMB_VFS_OP(shadow_copy2_get_nt_acl), SMB_VFS_OP_GET_NT_ACL, SMB_VFS_LAYER_TRANSPARENT},
-        {SMB_VFS_OP(shadow_copy2_set_nt_acl), SMB_VFS_OP_SET_NT_ACL, SMB_VFS_LAYER_TRANSPARENT},
 
         /* POSIX ACL operations */
         {SMB_VFS_OP(shadow_copy2_chmod_acl), SMB_VFS_OP_CHMOD_ACL, SMB_VFS_LAYER_TRANSPARENT},
index ce2e28771f7ca1193b6c037dd4d379602250b26a..e8a0507aa4e5584590e0342752f1011b13602f05 100644 (file)
@@ -212,14 +212,6 @@ static NTSTATUS zfsacl_fset_nt_acl(vfs_handle_struct *handle,
        return zfs_set_nt_acl(handle, fsp, security_info_sent, psd);
 }
 
-static NTSTATUS zfsacl_set_nt_acl(vfs_handle_struct *handle,
-                      files_struct *fsp,
-                      const char *name, uint32 security_info_sent,
-                      SEC_DESC *psd)
-{
-       return zfs_set_nt_acl(handle, fsp, security_info_sent, psd);
-}
-
 /* VFS operations structure */
 
 static vfs_op_tuple zfsacl_ops[] = {
@@ -229,8 +221,6 @@ static vfs_op_tuple zfsacl_ops[] = {
         SMB_VFS_LAYER_OPAQUE},
        {SMB_VFS_OP(zfsacl_fset_nt_acl), SMB_VFS_OP_FSET_NT_ACL,
         SMB_VFS_LAYER_OPAQUE},
-       {SMB_VFS_OP(zfsacl_set_nt_acl), SMB_VFS_OP_SET_NT_ACL,
-        SMB_VFS_LAYER_OPAQUE},
        {SMB_VFS_OP(NULL), SMB_VFS_OP_NOOP, SMB_VFS_LAYER_NOOP}
 };
 
index e9c7c7bb7cd6564da720e79da6a1d3b7b8db6401..bdbd8057183b835abb14c2680bc12f83672f0e12 100644 (file)
@@ -426,7 +426,6 @@ bool profile_setup(struct messaging_context *msg_ctx, bool rdonly)
            "NT_transact_set_user_quota",/* PR_VALUE_NT_TRANSACT_SET_USER_QUOTA */
            "get_nt_acl",               /* PR_VALUE_GET_NT_ACL */
            "fget_nt_acl",              /* PR_VALUE_FGET_NT_ACL */
-           "set_nt_acl",               /* PR_VALUE_SET_NT_ACL */
            "fset_nt_acl",              /* PR_VALUE_FSET_NT_ACL */
            "chmod_acl",                /* PR_VALUE_CHMOD_ACL */
            "fchmod_acl",               /* PR_VALUE_FCHMOD_ACL */
index 1b578cc9f87084c04f01c8220df5d43aac31942f..18c6f4de530a175a10f1a5d6594e1b3b7d5e9e11 100644 (file)
@@ -2233,7 +2233,7 @@ WERROR _srvsvc_NetSetFileSecurity(pipes_struct *p,
                }
        }
 
-       nt_status = SMB_VFS_SET_NT_ACL(fsp, fsp->fsp_name,
+       nt_status = SMB_VFS_FSET_NT_ACL(fsp,
                                       r->in.securityinformation,
                                       r->in.sd_buf->sd);
 
index ec4126c1f74bfaa0ef6e97a98a0f72cf0366bb6a..362823d78a55258b4273be39cf78847c2e9bc649 100644 (file)
@@ -770,13 +770,7 @@ static NTSTATUS set_sd(files_struct *fsp, uint8 *data, uint32 sd_len,
                security_info_sent &= ~DACL_SECURITY_INFORMATION;
        }
 
-       if (fsp->fh->fd != -1) {
-               status = SMB_VFS_FSET_NT_ACL(fsp, security_info_sent, psd);
-       }
-       else {
-               status = SMB_VFS_SET_NT_ACL(fsp, fsp->fsp_name,
-                                           security_info_sent, psd);
-       }
+       status = SMB_VFS_FSET_NT_ACL(fsp, security_info_sent, psd);
 
        TALLOC_FREE(psd);
 
index 6e75f99d35dcdb5617a6533e57ca5e335bc3706a..48814fedeab73659c153ef6a475d8c36133a8705 100644 (file)
@@ -356,8 +356,6 @@ bool status_profile_dump(bool verbose)
        d_printf("get_nt_acl_time:                %u\n", profile_p->get_nt_acl_time);
        d_printf("fget_nt_acl_count:              %u\n", profile_p->fget_nt_acl_count);
        d_printf("fget_nt_acl_time:               %u\n", profile_p->fget_nt_acl_time);
-       d_printf("set_nt_acl_count:               %u\n", profile_p->set_nt_acl_count);
-       d_printf("set_nt_acl_time:                %u\n", profile_p->set_nt_acl_time);
        d_printf("fset_nt_acl_count:              %u\n", profile_p->fset_nt_acl_count);
        d_printf("fset_nt_acl_time:               %u\n", profile_p->fset_nt_acl_time);
        d_printf("chmod_acl_count:                %u\n", profile_p->chmod_acl_count);