diff options
Diffstat (limited to 'winpr/libwinpr/sspi/NTLM/ntlm.c')
-rw-r--r-- | winpr/libwinpr/sspi/NTLM/ntlm.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/winpr/libwinpr/sspi/NTLM/ntlm.c b/winpr/libwinpr/sspi/NTLM/ntlm.c index 6a2ee6a..bc16a40 100644 --- a/winpr/libwinpr/sspi/NTLM/ntlm.c +++ b/winpr/libwinpr/sspi/NTLM/ntlm.c @@ -1255,7 +1255,10 @@ static SECURITY_STATUS SEC_ENTRY ntlm_MakeSignature(PCtxtHandle phContext, ULONG WINPR_HMAC_CTX* hmac = winpr_HMAC_New(); if (!winpr_HMAC_Init(hmac, WINPR_MD_MD5, context->SendSigningKey, WINPR_MD5_DIGEST_LENGTH)) + { + winpr_HMAC_Free(hmac); return SEC_E_INTERNAL_ERROR; + } Data_Write_UINT32(&seq_no, MessageSeqNo); winpr_HMAC_Update(hmac, (BYTE*)&seq_no, 4); @@ -1303,7 +1306,10 @@ static SECURITY_STATUS SEC_ENTRY ntlm_VerifySignature(PCtxtHandle phContext, WINPR_HMAC_CTX* hmac = winpr_HMAC_New(); if (!winpr_HMAC_Init(hmac, WINPR_MD_MD5, context->RecvSigningKey, WINPR_MD5_DIGEST_LENGTH)) + { + winpr_HMAC_Free(hmac); return SEC_E_INTERNAL_ERROR; + } Data_Write_UINT32(&seq_no, MessageSeqNo); winpr_HMAC_Update(hmac, (BYTE*)&seq_no, 4); |