summaryrefslogtreecommitdiff
path: root/source3/rpc_server
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2011-07-26 10:19:54 +1000
committerAndrew Bartlett <abartlet@samba.org>2011-08-03 18:48:04 +1000
commit8b983d232648944c18fe878a3ace0f58658ec24d (patch)
tree02555b34ad4f949ea300edf4a244ed9e471e5e5f /source3/rpc_server
parent902df836807b700b2d27877f2fa5284930df3ff7 (diff)
downloadsamba-8b983d232648944c18fe878a3ace0f58658ec24d.tar.gz
samba-8b983d232648944c18fe878a3ace0f58658ec24d.tar.bz2
samba-8b983d232648944c18fe878a3ace0f58658ec24d.zip
s3-ntlmssp Split auth_ntlmssp_start into two functions
This helps map on to the GENSEC semantics better, and ensures that the full set of desired features are set before the mechanism starts. Andrew Bartlett Signed-off-by: Andrew Tridgell <tridge@samba.org>
Diffstat (limited to 'source3/rpc_server')
-rw-r--r--source3/rpc_server/dcesrv_ntlmssp.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/source3/rpc_server/dcesrv_ntlmssp.c b/source3/rpc_server/dcesrv_ntlmssp.c
index fd5b820143..f9fbc060c5 100644
--- a/source3/rpc_server/dcesrv_ntlmssp.c
+++ b/source3/rpc_server/dcesrv_ntlmssp.c
@@ -36,9 +36,9 @@ NTSTATUS ntlmssp_server_auth_start(TALLOC_CTX *mem_ctx,
struct auth_ntlmssp_state *a = NULL;
NTSTATUS status;
- status = auth_ntlmssp_start(remote_address, &a);
+ status = auth_ntlmssp_prepare(remote_address, &a);
if (!NT_STATUS_IS_OK(status)) {
- DEBUG(0, (__location__ ": auth_ntlmssp_start failed: %s\n",
+ DEBUG(0, (__location__ ": auth_ntlmssp_prepare failed: %s\n",
nt_errstr(status)));
return status;
}
@@ -51,6 +51,13 @@ NTSTATUS ntlmssp_server_auth_start(TALLOC_CTX *mem_ctx,
auth_ntlmssp_want_feature(a, NTLMSSP_FEATURE_SEAL);
}
+ status = auth_ntlmssp_start(a);
+ if (!NT_STATUS_IS_OK(status)) {
+ DEBUG(0, (__location__ ": auth_ntlmssp_start failed: %s\n",
+ nt_errstr(status)));
+ return status;
+ }
+
status = auth_ntlmssp_update(a, mem_ctx, *token_in, token_out);
if (!NT_STATUS_EQUAL(status, NT_STATUS_MORE_PROCESSING_REQUIRED)) {
DEBUG(0, (__location__ ": auth_ntlmssp_update failed: %s\n",