Skip to content

Commit

Permalink
Add NTLM SIGN flag for SMB Server (#1826)
Browse files Browse the repository at this point in the history
Adds the NTLMSSP_NEGOTIATE_SIGN flag to the NTLM CHALLENGE message
returned by the SMB server. This is needeed for clients that generate a
SPNEGO mechListMIC which require signing to be enabled on the NTLM
context.
  • Loading branch information
jborean93 authored Jan 6, 2025
1 parent 06863ae commit 2d2e562
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions impacket/smbserver.py
Original file line number Diff line number Diff line change
Expand Up @@ -2926,6 +2926,8 @@ def smb2SessionSetup(connId, smbServer, recvPacket):
ansFlags |= ntlm.NTLMSSP_NEGOTIATE_UNICODE
if negotiateMessage['flags'] & ntlm.NTLM_NEGOTIATE_OEM:
ansFlags |= ntlm.NTLM_NEGOTIATE_OEM
if negotiateMessage['flags'] & ntlm.NTLMSSP_NEGOTIATE_SIGN:
ansFlags |= ntlm.NTLMSSP_NEGOTIATE_SIGN

ansFlags |= ntlm.NTLMSSP_NEGOTIATE_VERSION | ntlm.NTLMSSP_NEGOTIATE_TARGET_INFO | ntlm.NTLMSSP_TARGET_TYPE_SERVER | ntlm.NTLMSSP_NEGOTIATE_NTLM | ntlm.NTLMSSP_REQUEST_TARGET

Expand Down

0 comments on commit 2d2e562

Please sign in to comment.