]> git.ipfire.org Git - thirdparty/openssl.git/commit
Fix potential memory leak in OSSL_HPKE_CTX_new()
authorNiels Dossche <niels.dossche@ugent.be>
Sun, 27 Oct 2024 20:48:17 +0000 (21:48 +0100)
committerMatt Caswell <matt@openssl.org>
Wed, 30 Oct 2024 11:58:16 +0000 (11:58 +0000)
commit8ff6edb9da6199b130bfb50bc27b2e58cc815932
tree6d8bbced309632ac9ff75663e482f2baba61fba8
parent7e3f7f1dbbad187707db8bff2a4e8cf67f893ea8
Fix potential memory leak in OSSL_HPKE_CTX_new()

ctx->propq is a duplicated string, but the error code does not free
the duplicated string's memory. If e.g. EVP_CIPHER_fetch() fails then
we can leak the string's memory.

Reviewed-by: Tom Cosgrove <tom.cosgrove@arm.com>
Reviewed-by: Kurt Roeckx <kurt@roeckx.be>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25812)
crypto/hpke/hpke.c