]> git.baikalelectronics.ru Git - kernel.git/commit
SMB3: Fix crash in SMB2_open_init due to uninitialized field in compounding path
authorSteve French <stfrench@microsoft.com>
Tue, 10 Dec 2019 04:34:10 +0000 (22:34 -0600)
committerSteve French <stfrench@microsoft.com>
Fri, 13 Dec 2019 06:49:38 +0000 (00:49 -0600)
commit1e2684d114500824f3100fd4589dca09a3b01de3
tree76c6262475b2accd47cdea53a80efcd5e187bcf9
parent6d5d19a80ff43abede782d84ea7b9d2e18b2429b
SMB3: Fix crash in SMB2_open_init due to uninitialized field in compounding path

Ran into an intermittent crash in
SMB2_open_init+0x2f6/0x970
due to oparms.cifs_sb not being initialized when called from:
smb2_compound_op+0x45d/0x1690
Zero the whole oparms struct in the compounding path before setting up the
oparms so we don't risk any uninitialized fields.

Fixes: 7190c76d4cc6 ("smb3: fix mode passed in on create for modetosid mount option")
Signed-off-by: Steve French <stfrench@microsoft.com>
Acked-by: Ronnie Sahlberg <lsahlber@redhat.com>
Reviewed-by: Pavel Shilovsky <pshilov@microsoft.com>
fs/cifs/smb2inode.c