Skip to content

Commit fbc5502

Browse files
authored
Merge pull request wolfSSL#9750 from douzzer/20260206-fixes
20260206-fixes
2 parents 8726611 + 51f5f87 commit fbc5502

File tree

3 files changed

+83
-79
lines changed

3 files changed

+83
-79
lines changed

.wolfssl_known_macro_extras

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ BLAKE2B_SELFTEST
3636
BLAKE2S_SELFTEST
3737
BLOCKING
3838
BSDKM_EXPORT_SYMS
39-
ENABLED_BSDKM_REGISTER
4039
BSP_DEFAULT_IO_CHANNEL_DEFINED
4140
BSP_LED_0
4241
BSP_LED_1
@@ -215,6 +214,7 @@ DTLS_RECEIVEFROM_NO_TIMEOUT_ON_INVALID_PEER
215214
ECCSI_ORDER_MORE_BITS_THAN_PRIME
216215
ECC_DUMP_OID
217216
ECDHE_SIZE
217+
ENABLED_BSDKM_REGISTER
218218
ENABLE_SECURE_SOCKETS_LOGS
219219
ESP32
220220
ESP8266
@@ -281,10 +281,10 @@ HAVE_INTEL_QAT_SYNC
281281
HAVE_INTEL_SPEEDUP
282282
HAVE_MDK_RTX
283283
HAVE_NETX_BSD
284-
HAVE_PKCS7_ECC_RAW_SIGN_CALLBACK
285-
HAVE_PKCS7_RSA_RAW_SIGN_CALLBACK
286284
HAVE_PKCS11_STATIC
287285
HAVE_PKCS11_V3_STATIC
286+
HAVE_PKCS7_ECC_RAW_SIGN_CALLBACK
287+
HAVE_PKCS7_RSA_RAW_SIGN_CALLBACK
288288
HAVE_POCO_LIB
289289
HAVE_RTP_SYS
290290
HAVE_SECURE_GETENV
@@ -636,7 +636,6 @@ WC_NO_VERBOSE_RNG
636636
WC_PKCS11_FIND_WITH_ID_ONLY
637637
WC_PROTECT_ENCRYPTED_MEM
638638
WC_RNG_BLOCKING
639-
WC_RSA_DIRECT
640639
WC_RSA_NONBLOCK
641640
WC_RSA_NONBLOCK_TIME
642641
WC_RSA_NO_FERMAT_CHECK

src/ssl_api_pk.c

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -84,14 +84,12 @@ static int check_cert_key_dev(word32 keyOID, byte* privKey, word32 privSz,
8484
type = DYNAMIC_TYPE_DILITHIUM;
8585
break;
8686
#endif
87-
#if defined(HAVE_FALCON)
87+
#if defined(HAVE_FALCON)
8888
case FALCON_LEVEL1k:
8989
case FALCON_LEVEL5k:
9090
type = DYNAMIC_TYPE_FALCON;
9191
break;
92-
#endif
93-
default:
94-
type = 0;
92+
#endif
9593
}
9694

9795
ret = CreateDevPrivateKey(&pkey, privKey, privSz, type, label, id, heap,
@@ -108,12 +106,12 @@ static int check_cert_key_dev(word32 keyOID, byte* privKey, word32 privSz,
108106
ret = wc_CryptoCb_RsaCheckPrivKey((RsaKey*)pkey, pubKey, pubSz);
109107
break;
110108
#endif
111-
#ifdef HAVE_ECC
109+
#ifdef HAVE_ECC
112110
case ECDSAk:
113111
ret = wc_CryptoCb_EccCheckPrivKey((ecc_key*)pkey, pubKey,
114112
pubSz);
115113
break;
116-
#endif
114+
#endif
117115
#if defined(HAVE_DILITHIUM)
118116
case ML_DSA_LEVEL2k:
119117
case ML_DSA_LEVEL3k:
@@ -127,13 +125,13 @@ static int check_cert_key_dev(word32 keyOID, byte* privKey, word32 privSz,
127125
WC_PQC_SIG_TYPE_DILITHIUM, pubKey, pubSz);
128126
break;
129127
#endif
130-
#if defined(HAVE_FALCON)
128+
#if defined(HAVE_FALCON)
131129
case FALCON_LEVEL1k:
132130
case FALCON_LEVEL5k:
133131
ret = wc_CryptoCb_PqcSignatureCheckPrivKey(pkey,
134132
WC_PQC_SIG_TYPE_FALCON, pubKey, pubSz);
135133
break;
136-
#endif
134+
#endif
137135
default:
138136
ret = 0;
139137
}
@@ -146,31 +144,31 @@ static int check_cert_key_dev(word32 keyOID, byte* privKey, word32 privSz,
146144
#endif
147145

148146
switch (keyOID) {
149-
#ifndef NO_RSA
147+
#ifndef NO_RSA
150148
case RSAk:
151-
#ifdef WC_RSA_PSS
149+
#ifdef WC_RSA_PSS
152150
case RSAPSSk:
153-
#endif
151+
#endif
154152
wc_FreeRsaKey((RsaKey*)pkey);
155153
break;
156-
#endif
154+
#endif
157155
#ifdef HAVE_ECC
158156
case ECDSAk:
159157
wc_ecc_free((ecc_key*)pkey);
160158
break;
161159
#endif
162-
#if defined(HAVE_DILITHIUM)
160+
#if defined(HAVE_DILITHIUM)
163161
case ML_DSA_LEVEL2k:
164162
case ML_DSA_LEVEL3k:
165163
case ML_DSA_LEVEL5k:
166-
#ifdef WOLFSSL_DILITHIUM_FIPS204_DRAFT
164+
#ifdef WOLFSSL_DILITHIUM_FIPS204_DRAFT
167165
case DILITHIUM_LEVEL2k:
168166
case DILITHIUM_LEVEL3k:
169167
case DILITHIUM_LEVEL5k:
170-
#endif
168+
#endif
171169
wc_dilithium_free((dilithium_key*)pkey);
172170
break;
173-
#endif
171+
#endif
174172
#if defined(HAVE_FALCON)
175173
case FALCON_LEVEL1k:
176174
case FALCON_LEVEL5k:

0 commit comments

Comments
 (0)