From 78e263676b6f75fed852db651887a099137e72cb Mon Sep 17 00:00:00 2001 From: Steve Holme Date: Sun, 14 Apr 2019 01:55:18 +0100 Subject: md4: Move the GNU TLS Nettle MD4 implementation out of the NTLM code --- lib/curl_ntlm_core.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'lib/curl_ntlm_core.c') diff --git a/lib/curl_ntlm_core.c b/lib/curl_ntlm_core.c index ce6f22392..d840aed47 100644 --- a/lib/curl_ntlm_core.c +++ b/lib/curl_ntlm_core.c @@ -79,7 +79,7 @@ #elif defined(USE_GNUTLS_NETTLE) # include -# include +# include "curl_md4.h" #elif defined(USE_GNUTLS) @@ -578,10 +578,7 @@ CURLcode Curl_ntlm_core_mk_nt_hash(struct Curl_easy *data, Curl_md4it(ntbuffer, pw, 2 * len); #endif #elif defined(USE_GNUTLS_NETTLE) - struct md4_ctx MD4pw; - md4_init(&MD4pw); - md4_update(&MD4pw, (unsigned int)(2 * len), pw); - md4_digest(&MD4pw, MD4_DIGEST_SIZE, ntbuffer); + Curl_md4it(ntbuffer, pw, 2 * len); #elif defined(USE_GNUTLS) gcry_md_hd_t MD4pw; gcry_md_open(&MD4pw, GCRY_MD_MD4, 0); -- cgit v1.2.3