Test aes_free( NULL ) unconditionally

This commit is contained in:
Manuel Pégourié-Gonnard 2018-12-12 12:04:51 +01:00
parent 54e7f312d3
commit a4251f4775
2 changed files with 8 additions and 3 deletions

View file

@ -394,13 +394,15 @@ void aes_invalid_param( )
TEST_INVALID_PARAM_RET( MBEDTLS_ERR_AES_BAD_INPUT_DATA,
mbedtls_aes_setkey_dec( &dummy_ctx, NULL, 128 ) );
}
/* END_CASE */
/* BEGIN_CASE */
void aes_valid_param( )
{
/* These calls accept NULL */
TEST_VALID_PARAM( mbedtls_aes_free( NULL ) );
TEST_VALID_PARAM( mbedtls_aes_xts_free( NULL ) );
exit:
return;
}
/* END_CASE */

View file

@ -13,6 +13,9 @@ aes_decrypt_cbc:"000000000000000000000000000000000000000000000000000000000000000
AES - Invalid parameters
aes_invalid_param:
AES - Valid parameters
aes_valid_param:
AES Selftest
depends_on:MBEDTLS_SELF_TEST
aes_selftest: