summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source4/libcli/smb2/session.c8
-rw-r--r--source4/libcli/smb2/smb2.h1
2 files changed, 5 insertions, 4 deletions
diff --git a/source4/libcli/smb2/session.c b/source4/libcli/smb2/session.c
index 976880857d..097411813a 100644
--- a/source4/libcli/smb2/session.c
+++ b/source4/libcli/smb2/session.c
@@ -213,14 +213,16 @@ static void smb2_session_setup_spnego_done(struct tevent_req *subreq)
}
if (NT_STATUS_IS_OK(peer_status) && NT_STATUS_IS_OK(state->gensec_status)) {
- status = gensec_session_key(session->gensec, session,
- &session->session_key);
+ DATA_BLOB session_key;
+
+ status = gensec_session_key(session->gensec, state,
+ &session_key);
if (tevent_req_nterror(req, status)) {
return;
}
status = smb2cli_session_set_session_key(session->smbXcli,
- session->session_key,
+ session_key,
recv_iov);
if (tevent_req_nterror(req, status)) {
return;
diff --git a/source4/libcli/smb2/smb2.h b/source4/libcli/smb2/smb2.h
index 6d66e7a7e4..1cff5eac59 100644
--- a/source4/libcli/smb2/smb2.h
+++ b/source4/libcli/smb2/smb2.h
@@ -116,7 +116,6 @@ struct smb2_session {
struct smb2_transport *transport;
struct gensec_security *gensec;
uint32_t pid;
- DATA_BLOB session_key;
struct smbXcli_session *smbXcli;
};