summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
Diffstat (limited to 'source4')
-rw-r--r--source4/rpc_server/dcerpc_server.h1
-rw-r--r--source4/rpc_server/dcesrv_crypto.c8
-rw-r--r--source4/rpc_server/dcesrv_crypto_ntlmssp.c13
3 files changed, 21 insertions, 1 deletions
diff --git a/source4/rpc_server/dcerpc_server.h b/source4/rpc_server/dcerpc_server.h
index 386da6fc57..bc5376b6ce 100644
--- a/source4/rpc_server/dcerpc_server.h
+++ b/source4/rpc_server/dcerpc_server.h
@@ -100,6 +100,7 @@ struct dcesrv_crypto_ops {
NTSTATUS (*start)(struct dcesrv_auth *auth);
NTSTATUS (*update)(struct dcesrv_auth *auth, TALLOC_CTX *out_mem_ctx,
const DATA_BLOB in, DATA_BLOB *out);
+ NTSTATUS (*session_info)(struct dcesrv_auth *auth, struct auth_session_info **session_info);
NTSTATUS (*seal)(struct dcesrv_auth *auth, TALLOC_CTX *sig_mem_ctx,
uint8_t *data, size_t length, DATA_BLOB *sig);
NTSTATUS (*sign)(struct dcesrv_auth *auth, TALLOC_CTX *sig_mem_ctx,
diff --git a/source4/rpc_server/dcesrv_crypto.c b/source4/rpc_server/dcesrv_crypto.c
index 6d46388c97..b8dfe46835 100644
--- a/source4/rpc_server/dcesrv_crypto.c
+++ b/source4/rpc_server/dcesrv_crypto.c
@@ -84,6 +84,14 @@ NTSTATUS dcesrv_crypto_update(struct dcesrv_auth *auth,
}
/*
+ get auth_session_info state
+*/
+NTSTATUS dcesrv_crypto_session_info(struct dcesrv_auth *auth, struct auth_session_info **session_info)
+{
+ return auth->crypto_ctx.ops->session_info(auth, session_info);
+}
+
+/*
seal a packet
*/
NTSTATUS dcesrv_crypto_seal(struct dcesrv_auth *auth, TALLOC_CTX *sig_mem_ctx,
diff --git a/source4/rpc_server/dcesrv_crypto_ntlmssp.c b/source4/rpc_server/dcesrv_crypto_ntlmssp.c
index 0f1939ea1b..5fb6345599 100644
--- a/source4/rpc_server/dcesrv_crypto_ntlmssp.c
+++ b/source4/rpc_server/dcesrv_crypto_ntlmssp.c
@@ -52,7 +52,17 @@ static NTSTATUS dcesrv_crypto_ntlmssp_update(struct dcesrv_auth *auth, TALLOC_CT
{
struct auth_ntlmssp_state *auth_ntlmssp_state = auth->crypto_ctx.private_data;
- return ntlmssp_update(auth_ntlmssp_state->ntlmssp_state, out_mem_ctx, in, out);
+ return auth_ntlmssp_update(auth_ntlmssp_state, out_mem_ctx, in, out);
+}
+
+/*
+ get auth_session_info state
+*/
+static NTSTATUS dcesrv_crypto_ntlmssp_session_info(struct dcesrv_auth *auth, struct auth_session_info **session_info)
+{
+ struct auth_ntlmssp_state *auth_ntlmssp_state = auth->crypto_ctx.private_data;
+
+ return auth_ntlmssp_get_session_info(auth_ntlmssp_state, session_info);
}
/*
@@ -118,6 +128,7 @@ static const struct dcesrv_crypto_ops dcesrv_crypto_ntlmssp_ops = {
.auth_type = DCERPC_AUTH_TYPE_NTLMSSP,
.start = dcesrv_crypto_ntlmssp_start,
.update = dcesrv_crypto_ntlmssp_update,
+ .session_info = dcesrv_crypto_ntlmssp_session_info,
.seal = dcesrv_crypto_ntlmssp_seal,
.sign = dcesrv_crypto_ntlmssp_sign,
.check_sig = dcesrv_crypto_ntlmssp_check_sig,