summaryrefslogtreecommitdiff
path: root/source4/kdc
diff options
context:
space:
mode:
authorGary Lockyer <gary@catalyst.net.nz>2018-04-12 06:41:30 +1200
committerAndrew Bartlett <abartlet@samba.org>2018-05-10 20:02:23 +0200
commit5c0345ea9bb34695dcd7be6c913748323bebe937 (patch)
tree91609b666973bd053448269313e9507672f74597 /source4/kdc
parentdaa7b60a60520c94367e9112246482bae71c5ccd (diff)
downloadsamba-5c0345ea9bb34695dcd7be6c913748323bebe937.tar.gz
samdb: Add remote address to connect
Signed-off-by: Gary Lockyer <gary@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'source4/kdc')
-rw-r--r--source4/kdc/db-glue.c8
-rw-r--r--source4/kdc/kdc-heimdal.c8
-rw-r--r--source4/kdc/kdc-service-mit.c1
-rw-r--r--source4/kdc/kpasswd-helper.c1
-rw-r--r--source4/kdc/kpasswd_glue.c8
5 files changed, 20 insertions, 6 deletions
diff --git a/source4/kdc/db-glue.c b/source4/kdc/db-glue.c
index c2dd236fdb0..bb428e45cbc 100644
--- a/source4/kdc/db-glue.c
+++ b/source4/kdc/db-glue.c
@@ -2774,8 +2774,12 @@ NTSTATUS samba_kdc_setup_db_ctx(TALLOC_CTX *mem_ctx, struct samba_kdc_base_conte
}
/* Setup the link to LDB */
- kdc_db_ctx->samdb = samdb_connect(kdc_db_ctx, base_ctx->ev_ctx,
- base_ctx->lp_ctx, session_info, 0);
+ kdc_db_ctx->samdb = samdb_connect(kdc_db_ctx,
+ base_ctx->ev_ctx,
+ base_ctx->lp_ctx,
+ session_info,
+ NULL,
+ 0);
if (kdc_db_ctx->samdb == NULL) {
DEBUG(1, ("samba_kdc_setup_db_ctx: Cannot open samdb for KDC backend!"));
talloc_free(kdc_db_ctx);
diff --git a/source4/kdc/kdc-heimdal.c b/source4/kdc/kdc-heimdal.c
index fcc1eb02edf..83ace269d5d 100644
--- a/source4/kdc/kdc-heimdal.c
+++ b/source4/kdc/kdc-heimdal.c
@@ -305,8 +305,12 @@ static void kdc_task_init(struct task_server *task)
/* get a samdb connection */
- kdc->samdb = samdb_connect(kdc, kdc->task->event_ctx, kdc->task->lp_ctx,
- system_session(kdc->task->lp_ctx), 0);
+ kdc->samdb = samdb_connect(kdc,
+ kdc->task->event_ctx,
+ kdc->task->lp_ctx,
+ system_session(kdc->task->lp_ctx),
+ NULL,
+ 0);
if (!kdc->samdb) {
DEBUG(1,("kdc_task_init: unable to connect to samdb\n"));
task_server_terminate(task, "kdc: krb5_init_context samdb connect failed", true);
diff --git a/source4/kdc/kdc-service-mit.c b/source4/kdc/kdc-service-mit.c
index e5b20ffb523..1d28fc4e6eb 100644
--- a/source4/kdc/kdc-service-mit.c
+++ b/source4/kdc/kdc-service-mit.c
@@ -303,6 +303,7 @@ void mitkdc_task_init(struct task_server *task)
kdc->task->event_ctx,
kdc->task->lp_ctx,
system_session(kdc->task->lp_ctx),
+ NULL,
0);
if (kdc->samdb == NULL) {
task_server_terminate(task,
diff --git a/source4/kdc/kpasswd-helper.c b/source4/kdc/kpasswd-helper.c
index 6de28375cba..995f54825b5 100644
--- a/source4/kdc/kpasswd-helper.c
+++ b/source4/kdc/kpasswd-helper.c
@@ -180,6 +180,7 @@ NTSTATUS kpasswd_samdb_set_password(TALLOC_CTX *mem_ctx,
event_ctx,
lp_ctx,
session_info,
+ NULL,
0);
if (samdb == NULL) {
return NT_STATUS_INTERNAL_DB_CORRUPTION;
diff --git a/source4/kdc/kpasswd_glue.c b/source4/kdc/kpasswd_glue.c
index b12a2093314..0addfdf58ea 100644
--- a/source4/kdc/kpasswd_glue.c
+++ b/source4/kdc/kpasswd_glue.c
@@ -79,8 +79,12 @@ NTSTATUS samdb_kpasswd_change_password(TALLOC_CTX *mem_ctx,
}
/* Start a SAM with user privileges for the password change */
- samdb = samdb_connect(mem_ctx, event_ctx, lp_ctx,
- session_info, 0);
+ samdb = samdb_connect(mem_ctx,
+ event_ctx,
+ lp_ctx,
+ session_info,
+ NULL,
+ 0);
if (!samdb) {
*error_string = "Failed to open samdb";
return NT_STATUS_ACCESS_DENIED;