From: Andrew Dinh Date: Wed, 7 Jan 2026 16:24:30 +0000 (+0900) Subject: PKCS12_item_decrypt_d2i_ex(): Check oct argument for NULL X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2c13bf15286328641a805eb3b7c97e27d42881fb;p=thirdparty%2Fopenssl.git PKCS12_item_decrypt_d2i_ex(): Check oct argument for NULL Fixes CVE-2025-69421 Reviewed-by: Nikola Pajkovsky Reviewed-by: Saša Nedvědický Reviewed-by: Eugene Syromiatnikov Reviewed-by: Tomas Mraz MergeDate: Mon Jan 26 19:56:08 2026 --- diff --git a/crypto/pkcs12/p12_decr.c b/crypto/pkcs12/p12_decr.c index 0745bc9b088..ec1d2ee54ae 100644 --- a/crypto/pkcs12/p12_decr.c +++ b/crypto/pkcs12/p12_decr.c @@ -146,6 +146,11 @@ void *PKCS12_item_decrypt_d2i_ex(const X509_ALGOR *algor, const ASN1_ITEM *it, void *ret; int outlen = 0; + if (oct == NULL) { + ERR_raise(ERR_LIB_PKCS12, ERR_R_PASSED_NULL_PARAMETER); + return NULL; + } + if (!PKCS12_pbe_crypt_ex(algor, pass, passlen, oct->data, oct->length, &out, &outlen, 0, libctx, propq)) return NULL;