From 31a06d356d578fc3a8a1b0b4edb15abceedbba28 Mon Sep 17 00:00:00 2001 From: Eric Blankenhorn Date: Mon, 6 Apr 2026 16:26:26 -0500 Subject: [PATCH] Fix from review --- src/internal.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/internal.c b/src/internal.c index e1ab4fd0..eec2b1f0 100644 --- a/src/internal.c +++ b/src/internal.c @@ -7205,13 +7205,15 @@ static int DoUserAuthRequestRsaCert(WOLFSSH* ssh, WS_UserAuthData_PublicKey* pk, if (ret == WS_SUCCESS) { int sigTypeOk = 0; - if (publicKeyTypeSz == pk->publicKeyTypeSz + if (publicKeyType != NULL + && publicKeyTypeSz == pk->publicKeyTypeSz && WMEMCMP(publicKeyType, pk->publicKeyType, publicKeyTypeSz) == 0) { sigTypeOk = 1; } #ifdef WOLFSSH_CERTS - else if (pk->publicKeyTypeSz == 14 + else if (publicKeyType != NULL + && pk->publicKeyTypeSz == 14 && WMEMCMP(pk->publicKeyType, "x509v3-ssh-rsa", 14) == 0) { /* RFC 6187 Section 5: the signature uses the underlying