]> git.baikalelectronics.ru Git - kernel.git/commit
CIFS: Fix SMB3 mount without specifying a security mechanism
authorPavel Shilovsky <pshilov@microsoft.com>
Wed, 12 Apr 2017 20:32:07 +0000 (13:32 -0700)
committerSteve French <smfrench@gmail.com>
Thu, 13 Apr 2017 15:03:26 +0000 (10:03 -0500)
commit92e8734311a3319f05a749ce81f4660512fc8ec7
tree605afa59035a55581d8fff5b0f985b9d69eedaff
parentfebc8c980d3de967f53bdcc948954ea14bd712d3
CIFS: Fix SMB3 mount without specifying a security mechanism

Commit 373dc5faa98f ("smb2: Enforce sec= mount option") changed the
behavior of a mount command to enforce a specified security mechanism
during mounting. On another hand according to the spec if SMB3 server
doesn't respond with a security context it implies that it supports
NTLMSSP. The current code doesn't keep it in mind and fails a mount
for such servers if no security mechanism is specified. Fix this by
indicating that a server supports NTLMSSP if a security context isn't
returned during negotiate phase. This allows the code to use NTLMSSP
by default for SMB3 mounts.

Signed-off-by: Pavel Shilovsky <pshilov@microsoft.com>
Signed-off-by: Steve French <smfrench@gmail.com>
fs/cifs/smb2pdu.c