summaryrefslogtreecommitdiff
path: root/source3/libnet
diff options
context:
space:
mode:
Diffstat (limited to 'source3/libnet')
-rw-r--r--source3/libnet/libnet_join.c7
-rw-r--r--source3/libnet/libnet_samsync.c3
2 files changed, 6 insertions, 4 deletions
diff --git a/source3/libnet/libnet_join.c b/source3/libnet/libnet_join.c
index 34fe3a72ab..28b2f6c654 100644
--- a/source3/libnet/libnet_join.c
+++ b/source3/libnet/libnet_join.c
@@ -35,6 +35,7 @@
#include "secrets.h"
#include "rpc_client/init_lsa.h"
#include "krb5_env.h"
+#include "../libcli/security/dom_sid.h"
/****************************************************************
****************************************************************/
@@ -744,7 +745,7 @@ static NTSTATUS libnet_join_lookup_dc_rpc(TALLOC_CTX *mem_ctx,
r->out.netbios_domain_name = info->dns.name.string;
r->out.dns_domain_name = info->dns.dns_domain.string;
r->out.forest_name = info->dns.dns_forest.string;
- r->out.domain_sid = sid_dup_talloc(mem_ctx, info->dns.sid);
+ r->out.domain_sid = dom_sid_dup(mem_ctx, info->dns.sid);
NT_STATUS_HAVE_NO_MEMORY(r->out.domain_sid);
}
@@ -758,7 +759,7 @@ static NTSTATUS libnet_join_lookup_dc_rpc(TALLOC_CTX *mem_ctx,
}
r->out.netbios_domain_name = info->account_domain.name.string;
- r->out.domain_sid = sid_dup_talloc(mem_ctx, info->account_domain.sid);
+ r->out.domain_sid = dom_sid_dup(mem_ctx, info->account_domain.sid);
NT_STATUS_HAVE_NO_MEMORY(r->out.domain_sid);
}
@@ -2008,7 +2009,7 @@ static WERROR libnet_DomainUnjoin(TALLOC_CTX *mem_ctx,
"Unable to fetch domain sid: are we joined?");
return WERR_SETUP_NOT_JOINED;
}
- r->in.domain_sid = sid_dup_talloc(mem_ctx, &sid);
+ r->in.domain_sid = dom_sid_dup(mem_ctx, &sid);
W_ERROR_HAVE_NO_MEMORY(r->in.domain_sid);
}
diff --git a/source3/libnet/libnet_samsync.c b/source3/libnet/libnet_samsync.c
index 6668be28b5..1b5b9c3b2f 100644
--- a/source3/libnet/libnet_samsync.c
+++ b/source3/libnet/libnet_samsync.c
@@ -28,6 +28,7 @@
#include "../libcli/auth/libcli_auth.h"
#include "../librpc/gen_ndr/ndr_netlogon.h"
#include "../librpc/gen_ndr/cli_netlogon.h"
+#include "../libcli/security/dom_sid.h"
/**
* Fix up the delta, dealing with encryption issues so that the final
@@ -72,7 +73,7 @@ NTSTATUS libnet_samsync_init_context(TALLOC_CTX *mem_ctx,
NT_STATUS_HAVE_NO_MEMORY(ctx);
if (domain_sid) {
- ctx->domain_sid = sid_dup_talloc(mem_ctx, domain_sid);
+ ctx->domain_sid = dom_sid_dup(mem_ctx, domain_sid);
NT_STATUS_HAVE_NO_MEMORY(ctx->domain_sid);
ctx->domain_sid_str = sid_string_talloc(mem_ctx, ctx->domain_sid);