From faab79e28e239b274ac53ababe4f0e2e2f486dd1 Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Tue, 13 Sep 2011 16:46:39 +0200 Subject: s3:winbindd_cm: make use of cli_state_security_mode() metze --- source3/winbindd/winbindd_cm.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'source3') diff --git a/source3/winbindd/winbindd_cm.c b/source3/winbindd/winbindd_cm.c index 807ad40d37..b631ab69a9 100644 --- a/source3/winbindd/winbindd_cm.c +++ b/source3/winbindd/winbindd_cm.c @@ -788,6 +788,7 @@ static NTSTATUS cm_prepare_connection(const struct winbindd_domain *domain, char *ipc_domain = NULL; char *ipc_password = NULL; int flags = 0; + uint16_t sec_mode = 0; struct named_mutex *mutex; @@ -910,7 +911,8 @@ static NTSTATUS cm_prepare_connection(const struct winbindd_domain *domain, cm_get_ipc_userpass(&ipc_username, &ipc_domain, &ipc_password); - if ((((*cli)->sec_mode & NEGOTIATE_SECURITY_CHALLENGE_RESPONSE) != 0) && + sec_mode = cli_state_security_mode(*cli); + if (((sec_mode & NEGOTIATE_SECURITY_CHALLENGE_RESPONSE) != 0) && (strlen(ipc_username) > 0)) { /* Only try authenticated if we have a username */ -- cgit