summaryrefslogtreecommitdiff
path: root/source4/winbind
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2010-09-13 12:15:52 +1000
committerAndrew Tridgell <tridge@samba.org>2010-09-15 15:39:34 +1000
commit94fb6120d80d05de0f24ea71a93c761517fd4231 (patch)
treed135a1b5cb2e01930c8307c61c63e76ef47734fa /source4/winbind
parentbd51d30809180b64c5c6fc98c2bd79040b93051c (diff)
downloadsamba-94fb6120d80d05de0f24ea71a93c761517fd4231.tar.gz
samba-94fb6120d80d05de0f24ea71a93c761517fd4231.tar.bz2
samba-94fb6120d80d05de0f24ea71a93c761517fd4231.zip
s4-secrets: fetch secure channel type with domain SID
The secure channel type is needed to work out what DC to connect to Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'source4/winbind')
-rw-r--r--source4/winbind/wb_server.c12
-rw-r--r--source4/winbind/wb_server.h1
2 files changed, 10 insertions, 3 deletions
diff --git a/source4/winbind/wb_server.c b/source4/winbind/wb_server.c
index ee44f0a240..96dab0acd5 100644
--- a/source4/winbind/wb_server.c
+++ b/source4/winbind/wb_server.c
@@ -239,7 +239,9 @@ static void winbind_task_init(struct task_server *task)
primary_sid = secrets_get_domain_sid(service,
service->task->event_ctx,
service->task->lp_ctx,
- lpcfg_netbios_name(service->task->lp_ctx), &errstring);
+ lpcfg_netbios_name(service->task->lp_ctx),
+ &service->sec_channel_type,
+ &errstring);
if (!primary_sid) {
char *message = talloc_asprintf(task,
"Cannot start Winbind (standalone configuration): %s: "
@@ -253,7 +255,9 @@ static void winbind_task_init(struct task_server *task)
primary_sid = secrets_get_domain_sid(service,
service->task->event_ctx,
service->task->lp_ctx,
- lpcfg_workgroup(service->task->lp_ctx), &errstring);
+ lpcfg_workgroup(service->task->lp_ctx),
+ &service->sec_channel_type,
+ &errstring);
if (!primary_sid) {
char *message = talloc_asprintf(task, "Cannot start Winbind (domain member): %s: "
"Have you joined the %s domain?",
@@ -266,7 +270,9 @@ static void winbind_task_init(struct task_server *task)
primary_sid = secrets_get_domain_sid(service,
service->task->event_ctx,
service->task->lp_ctx,
- lpcfg_workgroup(service->task->lp_ctx), &errstring);
+ lpcfg_workgroup(service->task->lp_ctx),
+ &service->sec_channel_type,
+ &errstring);
if (!primary_sid) {
char *message = talloc_asprintf(task, "Cannot start Winbind (domain controller): %s: "
"Have you provisioned the %s domain?",
diff --git a/source4/winbind/wb_server.h b/source4/winbind/wb_server.h
index 1ffb62e485..7fc778a97b 100644
--- a/source4/winbind/wb_server.h
+++ b/source4/winbind/wb_server.h
@@ -29,6 +29,7 @@ struct wbsrv_service {
struct task_server *task;
const struct dom_sid *primary_sid;
+ enum netr_SchannelType sec_channel_type;
struct wbsrv_domain *domains;
struct idmap_context *idmap_ctx;
const char *priv_pipe_dir;