mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2025-07-30 10:47:28 +02:00
Fix leak in wolfcrypt test app detected w/ WC_RSA_NO_PADDING set (#2145)
Fix leak in wolfCrypt test with `WC_RSA_NO_PADDING`
This commit is contained in:
committed by
David Garske
parent
3be4682cda
commit
1dcd6b92a0
@ -10111,7 +10111,7 @@ int rsa_no_pad_test(void)
|
|||||||
|| out == NULL || plain == NULL
|
|| out == NULL || plain == NULL
|
||||||
#endif
|
#endif
|
||||||
) {
|
) {
|
||||||
return -6900;
|
ERROR_OUT(-6900, exit_rsa_nopadding);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef USE_CERT_BUFFERS_1024
|
#ifdef USE_CERT_BUFFERS_1024
|
||||||
@ -10268,6 +10268,9 @@ int rsa_no_pad_test(void)
|
|||||||
ret = 0;
|
ret = 0;
|
||||||
|
|
||||||
exit_rsa_nopadding:
|
exit_rsa_nopadding:
|
||||||
|
XFREE(tmp, HEAP_HINT, DYNAMIC_TYPE_TMP_BUFFER);
|
||||||
|
FREE_VAR(out, HEAP_HINT);
|
||||||
|
FREE_VAR(plain, HEAP_HINT);
|
||||||
wc_FreeRsaKey(&key);
|
wc_FreeRsaKey(&key);
|
||||||
wc_FreeRng(&rng);
|
wc_FreeRng(&rng);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user