forked from wolfSSL/wolfssl
src/ssl_crypto.c: in wolfSSL_CMAC_CTX_free(), gate wc_CmacFree() on !FIPS || FIPS>=5.3.
This commit is contained in:
@ -2106,7 +2106,9 @@ void wolfSSL_CMAC_CTX_free(WOLFSSL_CMAC_CTX *ctx)
|
|||||||
if (ctx != NULL) {
|
if (ctx != NULL) {
|
||||||
/* Deallocate dynamically allocated fields. */
|
/* Deallocate dynamically allocated fields. */
|
||||||
if (ctx->internal != NULL) {
|
if (ctx->internal != NULL) {
|
||||||
|
#if (!defined(HAVE_FIPS) || FIPS_VERSION_GE(5, 3)) && !defined(HAVE_SELFTEST)
|
||||||
wc_CmacFree((Cmac*)ctx->internal);
|
wc_CmacFree((Cmac*)ctx->internal);
|
||||||
|
#endif
|
||||||
XFREE(ctx->internal, NULL, DYNAMIC_TYPE_CMAC);
|
XFREE(ctx->internal, NULL, DYNAMIC_TYPE_CMAC);
|
||||||
}
|
}
|
||||||
if (ctx->cctx != NULL) {
|
if (ctx->cctx != NULL) {
|
||||||
|
Reference in New Issue
Block a user