summaryrefslogtreecommitdiffstats
path: root/fs/cifs/cifsglob.h
diff options
context:
space:
mode:
authorSachin Prabhu2017-01-18 11:05:57 +0100
committerSteve French2017-03-03 06:13:37 +0100
commitef65aaede23f75977af56a8c330bb9be8c6e125c (patch)
tree6c7c8bc54081d74d2e4e579639af6f4f528eaf50 /fs/cifs/cifsglob.h
parentCIFS: Fix sparse warnings (diff)
downloadkernel-qcow2-linux-ef65aaede23f75977af56a8c330bb9be8c6e125c.tar.gz
kernel-qcow2-linux-ef65aaede23f75977af56a8c330bb9be8c6e125c.tar.xz
kernel-qcow2-linux-ef65aaede23f75977af56a8c330bb9be8c6e125c.zip
smb2: Enforce sec= mount option
If the security type specified using a mount option is not supported, the SMB2 session setup code changes the security type to RawNTLMSSP. We should instead fail the mount and return an error. The patch changes the code for SMB2 to make it similar to the code used for SMB1. Like in SMB1, we now use the global security flags to select the security method to be used when no security method is specified and to return an error when the requested auth method is not available. For SMB2, we also use ntlmv2 as a synonym for nltmssp. Signed-off-by: Sachin Prabhu <sprabhu@redhat.com> Acked-by: Pavel Shilovsky <pshilov@microsoft.com> Acked-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Steve French <smfrench@gmail.com>
Diffstat (limited to 'fs/cifs/cifsglob.h')
-rw-r--r--fs/cifs/cifsglob.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/cifs/cifsglob.h b/fs/cifs/cifsglob.h
index af224cda8697..d42dd3288647 100644
--- a/fs/cifs/cifsglob.h
+++ b/fs/cifs/cifsglob.h
@@ -443,6 +443,9 @@ struct smb_version_operations {
int (*is_transform_hdr)(void *buf);
int (*receive_transform)(struct TCP_Server_Info *,
struct mid_q_entry **);
+ enum securityEnum (*select_sectype)(struct TCP_Server_Info *,
+ enum securityEnum);
+
};
struct smb_version_values {