Skip to content

Commit 73c286a

Browse files
fix possible null dereference, CID 518681
1 parent a21542c commit 73c286a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/ssl_load.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1112,7 +1112,7 @@ static int ProcessBufferTryDecode(WOLFSSL_CTX* ctx, WOLFSSL* ssl,
11121112
matchAnyKey = 1;
11131113
}
11141114
#ifdef WC_RSA_PSS
1115-
if(*keyFormat == RSAPSSk) {
1115+
if((ret == 0) && (*keyFormat == RSAPSSk)) {
11161116
/*
11171117
Require logic to verify that the der is RSAPSSk (when *keyFormat == RSAPSSK),
11181118
and to detect that the der is RSAPSSk (when *keyFormat == 0).

0 commit comments

Comments
 (0)