summaryrefslogtreecommitdiff
path: root/source3/utils
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2003-09-19 21:57:46 +0000
committerJeremy Allison <jra@samba.org>2003-09-19 21:57:46 +0000
commit8139c5fcfa6bd26ce03af41c374f84be48343666 (patch)
treee96b2089507cba6c52d12c989f4c1d9a792785a4 /source3/utils
parent389bf06cde17871fe4d8ef4cecc1cf92ef91e6be (diff)
downloadsamba-8139c5fcfa6bd26ce03af41c374f84be48343666.tar.gz
samba-8139c5fcfa6bd26ce03af41c374f84be48343666.tar.bz2
samba-8139c5fcfa6bd26ce03af41c374f84be48343666.zip
Ensure that dup_sec_desc copies the 'type' field correctly. This caused
me to expose a type arguement to make_sec_desc(). We weren't copying the SE_DESC_DACL_AUTO_INHERITED flag which could cause errors on auto inherited checks. Jeremy. (This used to be commit 546b2271c08735ac1049a453abac996d794aa364)
Diffstat (limited to 'source3/utils')
-rw-r--r--source3/utils/smbcacls.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source3/utils/smbcacls.c b/source3/utils/smbcacls.c
index 58ee57b5dd..5a70d16884 100644
--- a/source3/utils/smbcacls.c
+++ b/source3/utils/smbcacls.c
@@ -389,7 +389,7 @@ static SEC_DESC *sec_desc_parse(char *str)
return NULL;
}
- ret = make_sec_desc(ctx,revision, owner_sid, grp_sid,
+ ret = make_sec_desc(ctx,revision, SEC_DESC_SELF_RELATIVE, owner_sid, grp_sid,
NULL, dacl, &sd_size);
SAFE_FREE(grp_sid);
@@ -504,7 +504,7 @@ static int owner_set(struct cli_state *cli, enum chown_mode change_mode,
return EXIT_FAILED;
}
- sd = make_sec_desc(ctx,old->revision,
+ sd = make_sec_desc(ctx,old->revision, old->type,
(change_mode == REQUEST_CHOWN) ? &sid : NULL,
(change_mode == REQUEST_CHGRP) ? &sid : NULL,
NULL, NULL, &sd_size);
@@ -679,7 +679,7 @@ static int cacl_set(struct cli_state *cli, char *filename,
sort_acl(old->dacl);
/* Create new security descriptor and set it */
- sd = make_sec_desc(ctx,old->revision, NULL, NULL,
+ sd = make_sec_desc(ctx,old->revision, old->type, NULL, NULL,
NULL, old->dacl, &sd_size);
fnum = cli_nt_create(cli, filename, WRITE_DAC_ACCESS);