diff options
Diffstat (limited to 'fs/cifs/cifssmb.c')
-rw-r--r-- | fs/cifs/cifssmb.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/fs/cifs/cifssmb.c b/fs/cifs/cifssmb.c index c65c3419dd37..4bda920d1f75 100644 --- a/fs/cifs/cifssmb.c +++ b/fs/cifs/cifssmb.c | |||
@@ -604,11 +604,14 @@ CIFSSMBNegotiate(unsigned int xid, struct cifsSesInfo *ses) | |||
604 | else | 604 | else |
605 | rc = -EINVAL; | 605 | rc = -EINVAL; |
606 | 606 | ||
607 | if (server->sec_kerberos || server->sec_mskerberos) | 607 | if (server->secType == Kerberos) { |
608 | server->secType = Kerberos; | 608 | if (!server->sec_kerberos && |
609 | else if (server->sec_ntlmssp) | 609 | !server->sec_mskerberos) |
610 | server->secType = RawNTLMSSP; | 610 | rc = -EOPNOTSUPP; |
611 | else | 611 | } else if (server->secType == RawNTLMSSP) { |
612 | if (!server->sec_ntlmssp) | ||
613 | rc = -EOPNOTSUPP; | ||
614 | } else | ||
612 | rc = -EOPNOTSUPP; | 615 | rc = -EOPNOTSUPP; |
613 | } | 616 | } |
614 | } else | 617 | } else |