summaryrefslogtreecommitdiffstats
path: root/fs/cifs/smb2misc.c
diff options
context:
space:
mode:
authorPavel Shilovsky <piastry@etersoft.ru>2011-12-27 13:22:00 +0100
committerPavel Shilovsky <pshilovsky@samba.org>2012-07-24 19:54:57 +0200
commit5478f9ba9a34d660eb3227dcd16314689c51f946 (patch)
tree6cb95588d403d5a962f6450b68d2daaf23566250 /fs/cifs/smb2misc.c
parentCIFS: Add capability to send SMB2 negotiate message (diff)
downloadlinux-5478f9ba9a34d660eb3227dcd16314689c51f946.tar.xz
linux-5478f9ba9a34d660eb3227dcd16314689c51f946.zip
CIFS: Add session setup/logoff capability for SMB2
Signed-off-by: Pavel Shilovsky <piastry@etersoft.ru> Signed-off-by: Steve French <smfrench@gmail.com>
Diffstat (limited to 'fs/cifs/smb2misc.c')
-rw-r--r--fs/cifs/smb2misc.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/cifs/smb2misc.c b/fs/cifs/smb2misc.c
index e4dede4ae058..10729a74da27 100644
--- a/fs/cifs/smb2misc.c
+++ b/fs/cifs/smb2misc.c
@@ -224,6 +224,11 @@ smb2_get_data_area_len(int *off, int *len, struct smb2_hdr *hdr)
((struct smb2_negotiate_rsp *)hdr)->SecurityBufferLength);
break;
case SMB2_SESSION_SETUP:
+ *off = le16_to_cpu(
+ ((struct smb2_sess_setup_rsp *)hdr)->SecurityBufferOffset);
+ *len = le16_to_cpu(
+ ((struct smb2_sess_setup_rsp *)hdr)->SecurityBufferLength);
+ break;
case SMB2_CREATE:
case SMB2_READ:
case SMB2_QUERY_INFO: