summaryrefslogtreecommitdiff
path: root/source4/utils
diff options
context:
space:
mode:
Diffstat (limited to 'source4/utils')
-rw-r--r--source4/utils/net/net_vampire.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source4/utils/net/net_vampire.c b/source4/utils/net/net_vampire.c
index f89739225d..00ae647016 100644
--- a/source4/utils/net/net_vampire.c
+++ b/source4/utils/net/net_vampire.c
@@ -24,6 +24,7 @@
#include "utils/net/net.h"
#include "libnet/libnet.h"
#include "librpc/gen_ndr/ndr_samr.h"
+#include "auth/auth.h"
static int net_samdump_keytab_usage(struct net_context *ctx, int argc, const char **argv)
{
@@ -150,7 +151,10 @@ int net_samsync_ldb(struct net_context *ctx, int argc, const char **argv)
r.in.machine_account = NULL;
r.in.binding_string = NULL;
- status = libnet_samsync_ldb(libnetctx, ctx->mem_ctx, &r);
+ /* Needed to override the ACLs on ldb */
+ r.in.session_info = system_session(libnetctx);
+
+ status = libnet_samsync_ldb(libnetctx, libnetctx, &r);
if (!NT_STATUS_IS_OK(status)) {
DEBUG(0,("libnet_samsync_ldb returned %s: %s\n",
nt_errstr(status),