* Patch "Set previous session id correctly on SMB3 reconnect" has been added to the 4.8-stable tree
@ 2016-10-26 9:25 gregkh
0 siblings, 0 replies; only message in thread
From: gregkh @ 2016-10-26 9:25 UTC (permalink / raw)
To: smfrench, davidgoe, gregkh, steve.french; +Cc: stable, stable-commits
This is a note to let you know that I've just added the patch titled
Set previous session id correctly on SMB3 reconnect
to the 4.8-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
set-previous-session-id-correctly-on-smb3-reconnect.patch
and it can be found in the queue-4.8 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.
>From c2afb8147e69819885493edf3a7c1ce03aaf2d4e Mon Sep 17 00:00:00 2001
From: Steve French <smfrench@gmail.com>
Date: Tue, 20 Sep 2016 22:56:13 -0500
Subject: Set previous session id correctly on SMB3 reconnect
From: Steve French <smfrench@gmail.com>
commit c2afb8147e69819885493edf3a7c1ce03aaf2d4e upstream.
Signed-off-by: Steve French <steve.french@primarydata.com>
Reported-by: David Goebel <davidgoe@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
fs/cifs/smb2pdu.c | 5 +++++
fs/cifs/smb2pdu.h | 2 +-
2 files changed, 6 insertions(+), 1 deletion(-)
--- a/fs/cifs/smb2pdu.c
+++ b/fs/cifs/smb2pdu.c
@@ -604,6 +604,7 @@ SMB2_sess_setup(const unsigned int xid,
char *security_blob = NULL;
unsigned char *ntlmssp_blob = NULL;
bool use_spnego = false; /* else use raw ntlmssp */
+ u64 previous_session = ses->Suid;
cifs_dbg(FYI, "Session Setup\n");
@@ -641,6 +642,10 @@ ssetup_ntlmssp_authenticate:
return rc;
req->hdr.SessionId = 0; /* First session, not a reauthenticate */
+
+ /* if reconnect, we need to send previous sess id, otherwise it is 0 */
+ req->PreviousSessionId = previous_session;
+
req->Flags = 0; /* MBZ */
/* to enable echos and oplocks */
req->hdr.CreditRequest = cpu_to_le16(3);
--- a/fs/cifs/smb2pdu.h
+++ b/fs/cifs/smb2pdu.h
@@ -276,7 +276,7 @@ struct smb2_sess_setup_req {
__le32 Channel;
__le16 SecurityBufferOffset;
__le16 SecurityBufferLength;
- __le64 PreviousSessionId;
+ __u64 PreviousSessionId;
__u8 Buffer[1]; /* variable length GSS security buffer */
} __packed;
Patches currently in stable-queue which might be from smfrench@gmail.com are
queue-4.8/fix-regression-which-breaks-dfs-mounting.patch
queue-4.8/cleanup-missing-frees-on-some-ioctls.patch
queue-4.8/smb3-guids-should-be-constructed-as-random-but-valid-uuids.patch
queue-4.8/clarify-locking-of-cifs-file-and-tcon-structures-and-make-more-granular.patch
queue-4.8/do-not-send-smb3-set_info-request-if-nothing-is-changing.patch
queue-4.8/set-previous-session-id-correctly-on-smb3-reconnect.patch
queue-4.8/cifs-limit-the-overall-credit-acquired.patch
queue-4.8/fs-cifs-keep-guid-when-assigning-fid-to-fileinfo.patch
queue-4.8/display-number-of-credits-available.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2016-10-26 9:25 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-10-26 9:25 Patch "Set previous session id correctly on SMB3 reconnect" has been added to the 4.8-stable tree gregkh
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).