summaryrefslogtreecommitdiff
path: root/source3/modules
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2010-06-02 23:35:44 +0200
committerGünther Deschner <gd@samba.org>2010-06-03 11:00:12 +0200
commita75436e3ee11fa1491bfa574523269be716fc892 (patch)
tree16b926c2956bfb9bbf2e4814c86bca985cd8d85a /source3/modules
parente24a59f932897888cadae31469366663aca1a414 (diff)
downloadsamba-a75436e3ee11fa1491bfa574523269be716fc892.tar.gz
samba-a75436e3ee11fa1491bfa574523269be716fc892.tar.bz2
samba-a75436e3ee11fa1491bfa574523269be716fc892.zip
s3-security: use shared SECINFO_DACL define.
Guenther
Diffstat (limited to 'source3/modules')
-rw-r--r--source3/modules/nfs4_acls.c4
-rw-r--r--source3/modules/onefs_acl.c6
-rw-r--r--source3/modules/vfs_acl_common.c20
-rw-r--r--source3/modules/vfs_afsacl.c2
4 files changed, 16 insertions, 16 deletions
diff --git a/source3/modules/nfs4_acls.c b/source3/modules/nfs4_acls.c
index 9f383cfc16..a6b9c6ed01 100644
--- a/source3/modules/nfs4_acls.c
+++ b/source3/modules/nfs4_acls.c
@@ -734,7 +734,7 @@ NTSTATUS smb_set_nt_acl_nfs4(files_struct *fsp,
DEBUG(10, ("smb_set_nt_acl_nfs4 invoked for %s\n", fsp_str_dbg(fsp)));
- if ((security_info_sent & (DACL_SECURITY_INFORMATION |
+ if ((security_info_sent & (SECINFO_DACL |
SECINFO_GROUP | SECINFO_OWNER)) == 0)
{
DEBUG(9, ("security_info_sent (0x%x) ignored\n",
@@ -784,7 +784,7 @@ NTSTATUS smb_set_nt_acl_nfs4(files_struct *fsp,
}
}
- if (!(security_info_sent & DACL_SECURITY_INFORMATION) || psd->dacl ==NULL) {
+ if (!(security_info_sent & SECINFO_DACL) || psd->dacl ==NULL) {
DEBUG(10, ("no dacl found; security_info_sent = 0x%x\n", security_info_sent));
return NT_STATUS_OK;
}
diff --git a/source3/modules/onefs_acl.c b/source3/modules/onefs_acl.c
index 4fa2e79c7b..7080f6c660 100644
--- a/source3/modules/onefs_acl.c
+++ b/source3/modules/onefs_acl.c
@@ -725,7 +725,7 @@ onefs_fget_nt_acl(vfs_handle_struct *handle, files_struct *fsp,
}
/* Copy DACL into ppdesc */
- if (security_info & DACL_SECURITY_INFORMATION) {
+ if (security_info & SECINFO_DACL) {
if (!onefs_acl_to_samba_acl(sd->dacl, &dacl)) {
status = NT_STATUS_INVALID_PARAMETER;
goto out;
@@ -860,13 +860,13 @@ NTSTATUS onefs_samba_sd_to_sd(uint32_t security_info_sent,
}
/* Setup DACL */
- if ((security_info_sent & DACL_SECURITY_INFORMATION) && (psd->dacl)) {
+ if ((security_info_sent & SECINFO_DACL) && (psd->dacl)) {
if (!onefs_samba_acl_to_acl(psd->dacl, &daclp, &ignore_aces,
snum))
return NT_STATUS_ACCESS_DENIED;
if (ignore_aces == true)
- *security_info_effective &= ~DACL_SECURITY_INFORMATION;
+ *security_info_effective &= ~SECINFO_DACL;
}
/* Setup SACL */
diff --git a/source3/modules/vfs_acl_common.c b/source3/modules/vfs_acl_common.c
index 59aa70310f..79eb533af7 100644
--- a/source3/modules/vfs_acl_common.c
+++ b/source3/modules/vfs_acl_common.c
@@ -38,7 +38,7 @@ static NTSTATUS store_acl_blob_fsp(vfs_handle_struct *handle,
#define HASH_SECURITY_INFO (SECINFO_OWNER | \
SECINFO_GROUP | \
- DACL_SECURITY_INFORMATION | \
+ SECINFO_DACL | \
SECINFO_SACL)
/*******************************************************************
@@ -377,7 +377,7 @@ static NTSTATUS get_nt_acl_internal(vfs_handle_struct *handle,
if (!(security_info & SECINFO_GROUP)) {
psd->group_sid = NULL;
}
- if (!(security_info & DACL_SECURITY_INFORMATION)) {
+ if (!(security_info & SECINFO_DACL)) {
psd->dacl = NULL;
}
if (!(security_info & SECINFO_SACL)) {
@@ -438,7 +438,7 @@ static NTSTATUS inherit_new_acl(vfs_handle_struct *handle,
return SMB_VFS_FSET_NT_ACL(fsp,
(SECINFO_OWNER |
SECINFO_GROUP |
- DACL_SECURITY_INFORMATION),
+ SECINFO_DACL),
psd);
}
@@ -461,7 +461,7 @@ static NTSTATUS check_parent_acl_common(vfs_handle_struct *handle,
parent_name,
(SECINFO_OWNER |
SECINFO_GROUP |
- DACL_SECURITY_INFORMATION),
+ SECINFO_DACL),
&parent_desc);
if (!NT_STATUS_IS_OK(status)) {
@@ -534,7 +534,7 @@ static int open_acl_common(vfs_handle_struct *handle,
fname,
(SECINFO_OWNER |
SECINFO_GROUP |
- DACL_SECURITY_INFORMATION),
+ SECINFO_DACL),
&pdesc);
if (NT_STATUS_IS_OK(status)) {
/* See if we can access it. */
@@ -680,10 +680,10 @@ static NTSTATUS fset_nt_acl_common(vfs_handle_struct *handle, files_struct *fsp,
if ((security_info_sent & (SECINFO_OWNER|
SECINFO_GROUP|
- DACL_SECURITY_INFORMATION)) !=
+ SECINFO_DACL)) !=
(SECINFO_OWNER|
SECINFO_GROUP|
- DACL_SECURITY_INFORMATION)) {
+ SECINFO_DACL)) {
/* No we don't - read from the existing SD. */
struct security_descriptor *nc_psd = NULL;
@@ -691,7 +691,7 @@ static NTSTATUS fset_nt_acl_common(vfs_handle_struct *handle, files_struct *fsp,
NULL,
(SECINFO_OWNER|
SECINFO_GROUP|
- DACL_SECURITY_INFORMATION),
+ SECINFO_DACL),
&nc_psd);
if (!NT_STATUS_IS_OK(status)) {
@@ -709,13 +709,13 @@ static NTSTATUS fset_nt_acl_common(vfs_handle_struct *handle, files_struct *fsp,
}
security_info_sent |= SECINFO_GROUP;
- if (security_info_sent & DACL_SECURITY_INFORMATION) {
+ if (security_info_sent & SECINFO_DACL) {
nc_psd->dacl = dup_sec_acl(talloc_tos(), psd->dacl);
if (nc_psd->dacl == NULL) {
return NT_STATUS_NO_MEMORY;
}
}
- security_info_sent |= DACL_SECURITY_INFORMATION;
+ security_info_sent |= SECINFO_DACL;
psd = nc_psd;
}
diff --git a/source3/modules/vfs_afsacl.c b/source3/modules/vfs_afsacl.c
index f2ff474f06..dacd58f7ae 100644
--- a/source3/modules/vfs_afsacl.c
+++ b/source3/modules/vfs_afsacl.c
@@ -731,7 +731,7 @@ static bool nt_to_afs_acl(const char *filename,
/* Currently we *only* look at the dacl */
- if (((security_info_sent & DACL_SECURITY_INFORMATION) == 0) ||
+ if (((security_info_sent & SECINFO_DACL) == 0) ||
(psd->dacl == NULL))
return True;