summaryrefslogtreecommitdiff
path: root/fs/cifs
diff options
context:
space:
mode:
authorSteve French <smfrench@gmail.com>2017-09-19 23:40:03 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-10-05 07:44:01 (GMT)
commitdf1be2066433d6381efe5b092e7f662a4f1dada2 (patch)
treec7c8e29ca5de7eaa6f3c21f75930331e6b61451b /fs/cifs
parentf2d395b7bde53926bbca40e6e091e7fe4a644b4b (diff)
downloadlinux-df1be2066433d6381efe5b092e7f662a4f1dada2.tar.xz
SMB3: Warn user if trying to sign connection that authenticated as guest
commit c721c38957fb19982416f6be71aae7b30630d83b upstream. It can be confusing if user ends up authenticated as guest but they requested signing (server will return error validating signed packets) so add log message for this. Signed-off-by: Steve French <smfrench@gmail.com> Reviewed-by: Ronnie Sahlberg <lsahlber@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/cifs')
-rw-r--r--fs/cifs/smb2pdu.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/cifs/smb2pdu.c b/fs/cifs/smb2pdu.c
index 9d8ad4b..b98d96a 100644
--- a/fs/cifs/smb2pdu.c
+++ b/fs/cifs/smb2pdu.c
@@ -1010,6 +1010,8 @@ SMB2_sess_setup(const unsigned int xid, struct cifs_ses *ses,
while (sess_data->func)
sess_data->func(sess_data);
+ if ((ses->session_flags & SMB2_SESSION_FLAG_IS_GUEST) && (ses->sign))
+ cifs_dbg(VFS, "signing requested but authenticated as guest\n");
rc = sess_data->result;
out:
kfree(sess_data);