summaryrefslogtreecommitdiff
path: root/source4/libcli/security/sddl.c
diff options
context:
space:
mode:
Diffstat (limited to 'source4/libcli/security/sddl.c')
-rw-r--r--source4/libcli/security/sddl.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/source4/libcli/security/sddl.c b/source4/libcli/security/sddl.c
index 4342a7b87a..d4efab9b64 100644
--- a/source4/libcli/security/sddl.c
+++ b/source4/libcli/security/sddl.c
@@ -405,7 +405,7 @@ static char *sddl_flags_to_string(TALLOC_CTX *mem_ctx, const struct flag_map *ma
/* now by bits */
for (i=0;map[i].name;i++) {
if ((flags & map[i].flag) != 0) {
- s = talloc_asprintf_append(s, "%s", map[i].name);
+ s = talloc_asprintf_append_buffer(s, "%s", map[i].name);
if (s == NULL) goto failed;
flags &= ~map[i].flag;
}
@@ -532,7 +532,7 @@ static char *sddl_encode_acl(TALLOC_CTX *mem_ctx, const struct security_acl *acl
for (i=0;i<acl->num_aces;i++) {
char *ace = sddl_encode_ace(sddl, &acl->aces[i], domain_sid);
if (ace == NULL) goto failed;
- sddl = talloc_asprintf_append(sddl, "(%s)", ace);
+ sddl = talloc_asprintf_append_buffer(sddl, "(%s)", ace);
if (sddl == NULL) goto failed;
talloc_free(ace);
}
@@ -563,28 +563,28 @@ char *sddl_encode(TALLOC_CTX *mem_ctx, const struct security_descriptor *sd,
if (sd->owner_sid != NULL) {
char *sid = sddl_encode_sid(tmp_ctx, sd->owner_sid, domain_sid);
if (sid == NULL) goto failed;
- sddl = talloc_asprintf_append(sddl, "O:%s", sid);
+ sddl = talloc_asprintf_append_buffer(sddl, "O:%s", sid);
if (sddl == NULL) goto failed;
}
if (sd->group_sid != NULL) {
char *sid = sddl_encode_sid(tmp_ctx, sd->group_sid, domain_sid);
if (sid == NULL) goto failed;
- sddl = talloc_asprintf_append(sddl, "G:%s", sid);
+ sddl = talloc_asprintf_append_buffer(sddl, "G:%s", sid);
if (sddl == NULL) goto failed;
}
if ((sd->type & SEC_DESC_DACL_PRESENT) && sd->dacl != NULL) {
char *acl = sddl_encode_acl(tmp_ctx, sd->dacl, sd->type, domain_sid);
if (acl == NULL) goto failed;
- sddl = talloc_asprintf_append(sddl, "D:%s", acl);
+ sddl = talloc_asprintf_append_buffer(sddl, "D:%s", acl);
if (sddl == NULL) goto failed;
}
if ((sd->type & SEC_DESC_SACL_PRESENT) && sd->sacl != NULL) {
char *acl = sddl_encode_acl(tmp_ctx, sd->sacl, sd->type>>1, domain_sid);
if (acl == NULL) goto failed;
- sddl = talloc_asprintf_append(sddl, "S:%s", acl);
+ sddl = talloc_asprintf_append_buffer(sddl, "S:%s", acl);
if (sddl == NULL) goto failed;
}