From 00c84ced250ef9dc0a8b415453638b1ac7bf2457 Mon Sep 17 00:00:00 2001 From: Kareem Date: Thu, 4 Jun 2026 17:02:10 -0700 Subject: [PATCH] Confirm keys-params is not NULL before dereferencing in wc_XmssKey_GetPubLen. Fixes F-3980. --- wolfcrypt/src/wc_xmss.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wolfcrypt/src/wc_xmss.c b/wolfcrypt/src/wc_xmss.c index 576e109e70..9ad311d0ba 100644 --- a/wolfcrypt/src/wc_xmss.c +++ b/wolfcrypt/src/wc_xmss.c @@ -1575,7 +1575,7 @@ int wc_XmssKey_GetPubLen(const XmssKey* key, word32* len) int ret = 0; /* Validate parameters. */ - if ((key == NULL) || (len == NULL)) { + if ((key == NULL) || (key->params == NULL) || (len == NULL)) { ret = BAD_FUNC_ARG; } else {