Skip to content

Commit 0279a3e

Browse files
committed
Fix dummy signature generation
When always sign is set but no sign or seal was negotiated we mistakenly set the sequence number ionstead of the signature version in the signature version field. Signed-off-by: Simo Sorce <[email protected]>
1 parent 26b3b6b commit 0279a3e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/ntlm_crypto.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -847,8 +847,8 @@ int ntlm_sign(uint32_t flags, int direction,
847847
return 0;
848848

849849
} else if (flags & NTLMSSP_NEGOTIATE_ALWAYS_SIGN) {
850-
uint32_t le_seq = htole32(h->seq_num);
851-
memcpy(signature->data, &le_seq, 4);
850+
uint32_t sig_ver = htole32(NTLMSSP_MESSAGE_SIGNATURE_VERSION);
851+
memcpy(signature->data, &sig_ver, 4);
852852
memset(&signature->data[4], 0, 12);
853853
return 0;
854854
}

0 commit comments

Comments
 (0)