From: Shirish Pargaonkar <shirishpargaonkar@xxxxxxxxx> This happens in for-next branch. sign enable and sign required bits are different in smb and smb2 negprot response so a mount with sec=xi option fails for smb2. Signed-off-by: Shirish Pargaonkar <shirishpargaonkar@xxxxxxxxx> --- fs/cifs/cifssmb.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/fs/cifs/cifssmb.c b/fs/cifs/cifssmb.c index a35aad2..46f2ec1 100644 --- a/fs/cifs/cifssmb.c +++ b/fs/cifs/cifssmb.c @@ -407,8 +407,10 @@ decode_ext_sec_blob(struct cifs_ses *ses, NEGOTIATE_RSP *pSMBr) int cifs_enable_signing(struct TCP_Server_Info *server, bool mnt_sign_required) { - bool srv_sign_required = server->sec_mode & SECMODE_SIGN_REQUIRED; - bool srv_sign_enabled = server->sec_mode & SECMODE_SIGN_ENABLED; + bool srv_sign_required = server->sec_mode & SECMODE_SIGN_REQUIRED || + server->sec_mode & SMB2_NEGOTIATE_SIGNING_REQUIRED; + bool srv_sign_enabled = server->sec_mode & SECMODE_SIGN_ENABLED || + server->sec_mode & SMB2_NEGOTIATE_SIGNING_ENABLED; bool mnt_sign_enabled = global_secflags & CIFSSEC_MAY_SIGN; /* -- 1.7.12.4 -- To unsubscribe from this list: send the line "unsubscribe linux-cifs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html