From 336b6a32c0c9bec6bf6ccfc5942a3ce62ff34281 Mon Sep 17 00:00:00 2001 From: Wyatt O'Day Date: Mon, 2 Apr 2018 13:33:00 -0400 Subject: tls: fix mbedTLS 2.7.0 build + handle sha256 failures (mbedtls 2.70 compiled with MBEDTLS_DEPRECATED_REMOVED) Closes #2453 --- lib/vtls/openssl.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/vtls/openssl.c') diff --git a/lib/vtls/openssl.c b/lib/vtls/openssl.c index fc9ad47ad..205d303ed 100644 --- a/lib/vtls/openssl.c +++ b/lib/vtls/openssl.c @@ -3603,7 +3603,7 @@ static CURLcode Curl_ossl_md5sum(unsigned char *tmp, /* input */ } #if (OPENSSL_VERSION_NUMBER >= 0x0090800fL) && !defined(OPENSSL_NO_SHA256) -static void Curl_ossl_sha256sum(const unsigned char *tmp, /* input */ +static CURLcode Curl_ossl_sha256sum(const unsigned char *tmp, /* input */ size_t tmplen, unsigned char *sha256sum /* output */, size_t unused) @@ -3617,6 +3617,7 @@ static void Curl_ossl_sha256sum(const unsigned char *tmp, /* input */ EVP_DigestUpdate(mdctx, tmp, tmplen); EVP_DigestFinal_ex(mdctx, sha256sum, &len); EVP_MD_CTX_destroy(mdctx); + return CURLE_OK; } #endif -- cgit v1.2.3