summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
Diffstat (limited to 'source3')
-rw-r--r--source3/auth/auth_ntlmssp.c11
-rw-r--r--source3/auth/proto.h3
-rw-r--r--source3/rpc_server/dcesrv_ntlmssp.c3
-rw-r--r--source3/smbd/sesssetup.c5
-rw-r--r--source3/smbd/smb2_sesssetup.c12
5 files changed, 11 insertions, 23 deletions
diff --git a/source3/auth/auth_ntlmssp.c b/source3/auth/auth_ntlmssp.c
index e22db822ab..b57fda1ea7 100644
--- a/source3/auth/auth_ntlmssp.c
+++ b/source3/auth/auth_ntlmssp.c
@@ -31,17 +31,6 @@
#include "librpc/rpc/dcerpc.h"
#include "lib/param/param.h"
-NTSTATUS auth_ntlmssp_session_info(TALLOC_CTX *mem_ctx,
- struct auth_ntlmssp_state *auth_ntlmssp_state,
- struct auth_session_info **session_info)
-{
- NTSTATUS nt_status;
- nt_status = gensec_session_info(auth_ntlmssp_state->gensec_security,
- mem_ctx,
- session_info);
- return nt_status;
-}
-
static NTSTATUS gensec_ntlmssp3_server_session_info(struct gensec_security *gensec_security,
TALLOC_CTX *mem_ctx,
struct auth_session_info **session_info)
diff --git a/source3/auth/proto.h b/source3/auth/proto.h
index a7266d6e60..bc2d58a811 100644
--- a/source3/auth/proto.h
+++ b/source3/auth/proto.h
@@ -69,9 +69,6 @@ NTSTATUS auth_netlogond_init(void);
/* The following definitions come from auth/auth_ntlmssp.c */
-NTSTATUS auth_ntlmssp_session_info(TALLOC_CTX *mem_ctx,
- struct auth_ntlmssp_state *auth_ntlmssp_state,
- struct auth_session_info **session_info);
NTSTATUS auth_ntlmssp_prepare(const struct tsocket_address *remote_address,
struct auth_ntlmssp_state **auth_ntlmssp_state);
NTSTATUS auth_ntlmssp_start(struct auth_ntlmssp_state *auth_ntlmssp_state);
diff --git a/source3/rpc_server/dcesrv_ntlmssp.c b/source3/rpc_server/dcesrv_ntlmssp.c
index 076a48da43..04dd9e6521 100644
--- a/source3/rpc_server/dcesrv_ntlmssp.c
+++ b/source3/rpc_server/dcesrv_ntlmssp.c
@@ -23,6 +23,7 @@
#include "../auth/ntlmssp/ntlmssp.h"
#include "ntlmssp_wrap.h"
#include "auth.h"
+#include "auth/gensec/gensec.h"
NTSTATUS ntlmssp_server_auth_start(TALLOC_CTX *mem_ctx,
bool do_sign,
@@ -117,7 +118,7 @@ NTSTATUS ntlmssp_server_get_user_info(struct auth_ntlmssp_state *ctx,
{
NTSTATUS status;
- status = auth_ntlmssp_session_info(mem_ctx, ctx, session_info);
+ status = gensec_session_info(ctx->gensec_security, mem_ctx, session_info);
if (!NT_STATUS_IS_OK(status)) {
DEBUG(1, (__location__ ": Failed to get authenticated user "
"info: %s\n", nt_errstr(status)));
diff --git a/source3/smbd/sesssetup.c b/source3/smbd/sesssetup.c
index 4d48e73f92..a5f2030ee5 100644
--- a/source3/smbd/sesssetup.c
+++ b/source3/smbd/sesssetup.c
@@ -431,8 +431,9 @@ static void reply_spnego_ntlmssp(struct smb_request *req,
struct smbd_server_connection *sconn = req->sconn;
if (NT_STATUS_IS_OK(nt_status)) {
- nt_status = auth_ntlmssp_session_info(talloc_tos(),
- (*auth_ntlmssp_state), &session_info);
+ nt_status = gensec_session_info((*auth_ntlmssp_state)->gensec_security,
+ talloc_tos(),
+ &session_info);
}
reply_outbuf(req, 4, 0);
diff --git a/source3/smbd/smb2_sesssetup.c b/source3/smbd/smb2_sesssetup.c
index ece5de1282..aa898eaad7 100644
--- a/source3/smbd/smb2_sesssetup.c
+++ b/source3/smbd/smb2_sesssetup.c
@@ -588,9 +588,9 @@ static NTSTATUS smbd_smb2_spnego_auth(struct smbd_smb2_session *session,
/* If status is NT_STATUS_OK then we need to get the token.
* Map to guest is now internal to auth_ntlmssp */
if (NT_STATUS_IS_OK(status)) {
- status = auth_ntlmssp_session_info(session,
- session->auth_ntlmssp_state,
- &session->session_info);
+ status = gensec_session_info(session->auth_ntlmssp_state->gensec_security,
+ session,
+ &session->session_info);
}
if (!NT_STATUS_IS_OK(status) &&
@@ -671,9 +671,9 @@ static NTSTATUS smbd_smb2_raw_ntlmssp_auth(struct smbd_smb2_session *session,
return status;
}
- status = auth_ntlmssp_session_info(session,
- session->auth_ntlmssp_state,
- &session->session_info);
+ status = gensec_session_info(session->auth_ntlmssp_state->gensec_security,
+ session,
+ &session->session_info);
if (!NT_STATUS_IS_OK(status)) {
TALLOC_FREE(session->auth_ntlmssp_state);