From f9b042641f9c6615f6a4b102f0182de545d6a19a Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Mon, 17 Oct 2011 20:19:11 +1100 Subject: s3-ntlmssp split auth_ntlmssp_client_start() into two parts This will allow it to be a wrapper around a gensec module, which requires that they options be set on a context, but before the mechanism is started. This also simplfies the callers, by moving the lp_*() calls into one place. Andrew Bartlett --- source3/librpc/crypto/cli_spnego.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'source3/librpc') diff --git a/source3/librpc/crypto/cli_spnego.c b/source3/librpc/crypto/cli_spnego.c index 3420e20d27..4742158b24 100644 --- a/source3/librpc/crypto/cli_spnego.c +++ b/source3/librpc/crypto/cli_spnego.c @@ -99,10 +99,7 @@ NTSTATUS spnego_ntlmssp_init_client(TALLOC_CTX *mem_ctx, } sp_ctx->mech = SPNEGO_NTLMSSP; - status = auth_ntlmssp_client_start(sp_ctx, - lp_netbios_name(), - lp_workgroup(), - lp_client_ntlmv2_auth(), + status = auth_ntlmssp_client_prepare(sp_ctx, &sp_ctx->mech_ctx.ntlmssp_state); if (!NT_STATUS_IS_OK(status)) { TALLOC_FREE(sp_ctx); @@ -138,6 +135,12 @@ NTSTATUS spnego_ntlmssp_init_client(TALLOC_CTX *mem_ctx, NTLMSSP_FEATURE_SEAL); } + status = auth_ntlmssp_client_start(sp_ctx->mech_ctx.ntlmssp_state); + if (!NT_STATUS_IS_OK(status)) { + TALLOC_FREE(sp_ctx); + return status; + } + *spnego_ctx = sp_ctx; return NT_STATUS_OK; } -- cgit