mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-12-24 17:41:01 +03:00
Fix PSA SE driver tests
Fix PSA SE driver tests in configuration full + MBEDTLS_PSA_CRYPTO_DRIVERS. Signed-off-by: Ronald Cron <ronald.cron@arm.com>
This commit is contained in:
@@ -3558,6 +3558,12 @@ psa_status_t psa_cipher_generate_iv( psa_cipher_operation_t *operation,
|
||||
{
|
||||
psa_status_t status;
|
||||
int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
|
||||
if( operation->alg == 0 )
|
||||
{
|
||||
return( PSA_ERROR_BAD_STATE );
|
||||
}
|
||||
|
||||
if( operation->iv_set || ! operation->iv_required )
|
||||
{
|
||||
return( PSA_ERROR_BAD_STATE );
|
||||
@@ -3602,6 +3608,12 @@ psa_status_t psa_cipher_set_iv( psa_cipher_operation_t *operation,
|
||||
{
|
||||
psa_status_t status;
|
||||
int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
|
||||
|
||||
if( operation->alg == 0 )
|
||||
{
|
||||
return( PSA_ERROR_BAD_STATE );
|
||||
}
|
||||
|
||||
if( operation->iv_set || ! operation->iv_required )
|
||||
{
|
||||
return( PSA_ERROR_BAD_STATE );
|
||||
|
||||
Reference in New Issue
Block a user