]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blob - releases/4.4.177/cifs-fix-computation-for-max_smb2_hdr_size.patch
Linux 3.18.137
[thirdparty/kernel/stable-queue.git] / releases / 4.4.177 / cifs-fix-computation-for-max_smb2_hdr_size.patch
1 From 31fe3bc744857c762f5467a13bbff165afa9a6d4 Mon Sep 17 00:00:00 2001
2 From: Ronnie Sahlberg <lsahlber@redhat.com>
3 Date: Tue, 29 Jan 2019 12:46:16 +1000
4 Subject: cifs: fix computation for MAX_SMB2_HDR_SIZE
5
6 [ Upstream commit 58d15ed1203f4d858c339ea4d7dafa94bd2a56d3 ]
7
8 The size of the fixed part of the create response is 88 bytes not 56.
9
10 Signed-off-by: Ronnie Sahlberg <lsahlber@redhat.com>
11 Signed-off-by: Steve French <stfrench@microsoft.com>
12 Reviewed-by: Pavel Shilovsky <pshilov@microsoft.com>
13 Signed-off-by: Sasha Levin <sashal@kernel.org>
14 ---
15 fs/cifs/smb2pdu.h | 4 ++--
16 1 file changed, 2 insertions(+), 2 deletions(-)
17
18 diff --git a/fs/cifs/smb2pdu.h b/fs/cifs/smb2pdu.h
19 index aacb15bd56fe..f087158c5555 100644
20 --- a/fs/cifs/smb2pdu.h
21 +++ b/fs/cifs/smb2pdu.h
22 @@ -82,8 +82,8 @@
23
24 #define NUMBER_OF_SMB2_COMMANDS 0x0013
25
26 -/* 4 len + 52 transform hdr + 64 hdr + 56 create rsp */
27 -#define MAX_SMB2_HDR_SIZE 0x00b0
28 +/* 52 transform hdr + 64 hdr + 88 create rsp */
29 +#define MAX_SMB2_HDR_SIZE 204
30
31 #define SMB2_PROTO_NUMBER cpu_to_le32(0x424d53fe)
32
33 --
34 2.19.1
35