summaryrefslogtreecommitdiffstats
path: root/fs/cifs
diff options
context:
space:
mode:
authorSteve French <stfrench@microsoft.com>2020-02-28 01:32:37 -0600
committerSteve French <stfrench@microsoft.com>2020-03-22 22:49:09 -0500
commit8fe0c2c2cb7be631576637555d712247bc86f1bf (patch)
tree702299599085113506b097a320b751d580ec2df6 /fs/cifs
parentcf5371ae460eb8e484e4884747af270c86c3c469 (diff)
downloadlinux-8fe0c2c2cb7be631576637555d712247bc86f1bf.tar.gz
linux-8fe0c2c2cb7be631576637555d712247bc86f1bf.tar.bz2
linux-8fe0c2c2cb7be631576637555d712247bc86f1bf.zip
cifs: print warning mounting with vers=1.0
We really, really don't want people using insecure dialects unless they realize what they are doing ... Add mount warning if mounting with vers=1.0 (older SMB1/CIFS dialect) instead of the default (SMB2.1 or later, typically SMB3.1.1). Signed-off-by: Steve French <stfrench@microsoft.com> Acked-by: Ronnie Sahlberg <lsahlber@redhat.com> Acked-by: Pavel Shilovsky <pshilov@microsoft.com>
Diffstat (limited to 'fs/cifs')
-rw-r--r--fs/cifs/connect.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/cifs/connect.c b/fs/cifs/connect.c
index f4d12b79ceed..46b602dfc4d3 100644
--- a/fs/cifs/connect.c
+++ b/fs/cifs/connect.c
@@ -1471,6 +1471,9 @@ cifs_parse_smb_version(char *value, struct smb_vol *vol, bool is_smb3)
cifs_dbg(VFS, "vers=1.0 (cifs) not permitted when mounting with smb3\n");
return 1;
}
+ cifs_dbg(VFS, "Use of the less secure dialect vers=1.0 "
+ "is not recommended unless required for "
+ "access to very old servers\n");
vol->ops = &smb1_operations;
vol->vals = &smb1_values;
break;