Commit 18ca04616f for openssl.org
commit 18ca04616f69d7b1b173014ce3eb178b073a22cd
Author: Neil Horman <nhorman@openssl.org>
Date: Tue Jan 20 12:30:24 2026 -0500
Update SHA384_Update to do thunking
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Paul Dale <paul.dale@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/29650)
diff --git a/crypto/sha/sha512.c b/crypto/sha/sha512.c
index 473ec09b5f..45b8e7c332 100644
--- a/crypto/sha/sha512.c
+++ b/crypto/sha/sha512.c
@@ -333,7 +333,7 @@ int SHA512_Update(SHA512_CTX *c, const void *_data, size_t len)
int SHA384_Update(SHA512_CTX *c, const void *data, size_t len)
{
- return SHA512_Update(c, data, len);
+ return SHA512_Update_thunk((void *)c, (const unsigned char *)data, len);
}
void SHA512_Transform(SHA512_CTX *c, const unsigned char *data)
diff --git a/providers/implementations/digests/sha2_prov.c b/providers/implementations/digests/sha2_prov.c
index 607228a355..8c9114b58b 100644
--- a/providers/implementations/digests/sha2_prov.c
+++ b/providers/implementations/digests/sha2_prov.c
@@ -309,7 +309,7 @@ IMPLEMENT_digest_functions_with_serialize(sha256_192_internal, SHA256_CTX,
IMPLEMENT_digest_functions_with_serialize(sha384, SHA512_CTX,
SHA512_CBLOCK, SHA384_DIGEST_LENGTH,
SHA2_FLAGS, SHA384_Init,
- SHA384_Update, SHA384_Final,
+ SHA512_Update_thunk, SHA384_Final,
SHA512_Serialize, SHA512_Deserialize)
/* ossl_sha512_functions */