File openssl-CVE-2025-69421.patch of Package openssl-3.42399
From 0a2ecb95993b588d2156dd6527459cc3983aabd5 Mon Sep 17 00:00:00 2001
From: Andrew Dinh <andrewd@openssl.org>
Date: Thu, 8 Jan 2026 01:24:30 +0900
Subject: [PATCH] Add NULL check to PKCS12_item_decrypt_d2i_ex
Address CVE-2025-69421
Add NULL check for oct parameter
---
crypto/pkcs12/p12_decr.c | 5 +++++
1 file changed, 5 insertions(+)
Index: openssl-3.0.8/crypto/pkcs12/p12_decr.c
===================================================================
--- openssl-3.0.8.orig/crypto/pkcs12/p12_decr.c
+++ openssl-3.0.8/crypto/pkcs12/p12_decr.c
@@ -137,6 +137,11 @@ void *PKCS12_item_decrypt_d2i_ex(const X
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;