summaryrefslogtreecommitdiff
path: root/source4/librpc/rpc/dcerpc_auth.c
diff options
context:
space:
mode:
Diffstat (limited to 'source4/librpc/rpc/dcerpc_auth.c')
-rw-r--r--source4/librpc/rpc/dcerpc_auth.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/source4/librpc/rpc/dcerpc_auth.c b/source4/librpc/rpc/dcerpc_auth.c
index 9587fb9390..0966b70338 100644
--- a/source4/librpc/rpc/dcerpc_auth.c
+++ b/source4/librpc/rpc/dcerpc_auth.c
@@ -107,13 +107,16 @@ NTSTATUS dcerpc_bind_auth3(struct dcerpc_pipe *p, uint8_t auth_type, uint8_t aut
}
p->security_state.auth_info->credentials = credentials;
-
+
status = dcerpc_auth3(p, mem_ctx);
done:
talloc_destroy(mem_ctx);
if (!NT_STATUS_IS_OK(status)) {
ZERO_STRUCT(p->security_state);
+ } else {
+ /* Authenticated connections use the generic session key */
+ p->security_state.session_key = dcerpc_generic_session_key;
}
return status;
@@ -196,6 +199,9 @@ done:
if (!NT_STATUS_IS_OK(status)) {
ZERO_STRUCT(p->security_state);
+ } else {
+ /* Authenticated connections use the generic session key */
+ p->security_state.session_key = dcerpc_generic_session_key;
}
return status;