mirror of
https://github.com/TalAloni/SMBLibrary.git
synced 2025-04-30 10:47:48 +02:00
SMB2Client: Always sign outgoing messages when dialect is 3.1.1
This commit is contained in:
parent
2ef0fb968e
commit
2c4e42d956
1 changed files with 4 additions and 1 deletions
|
@ -217,7 +217,10 @@ namespace SMBLibrary.Client
|
|||
if (response != null && response.Header.Status == NTStatus.STATUS_SUCCESS)
|
||||
{
|
||||
m_dialect = response.DialectRevision;
|
||||
m_signingRequired = (response.SecurityMode & SecurityMode.SigningRequired) > 0;
|
||||
// [MS-SMB2] 3.3.5.7 If Connection.Dialect is "3.1.1" and Session.IsAnonymous and Session.IsGuest
|
||||
// are set to FALSE and the request is not signed or not encrypted, then the server MUST disconnect the connection.
|
||||
m_signingRequired = (response.SecurityMode & SecurityMode.SigningRequired) > 0 ||
|
||||
response.DialectRevision == SMB2Dialect.SMB311;
|
||||
m_maxTransactSize = Math.Min(response.MaxTransactSize, ClientMaxTransactSize);
|
||||
m_maxReadSize = Math.Min(response.MaxReadSize, ClientMaxReadSize);
|
||||
m_maxWriteSize = Math.Min(response.MaxWriteSize, ClientMaxWriteSize);
|
||||
|
|
Loading…
Add table
Reference in a new issue