mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-30 22:43:08 +03:00
Merge pull request #5076 from mstarzyk-mobica/psa_ccm_no_tag
PSA CCM*-no-tag
This commit is contained in:
@ -3595,7 +3595,12 @@ psa_status_t psa_cipher_decrypt( mbedtls_svc_key_id_t key,
|
||||
.core = slot->attr
|
||||
};
|
||||
|
||||
if( input_length < PSA_CIPHER_IV_LENGTH( slot->attr.type, alg ) )
|
||||
if( alg == PSA_ALG_CCM_STAR_NO_TAG && input_length < PSA_BLOCK_CIPHER_BLOCK_LENGTH( slot->attr.type ) )
|
||||
{
|
||||
status = PSA_ERROR_INVALID_ARGUMENT;
|
||||
goto exit;
|
||||
}
|
||||
else if ( input_length < PSA_CIPHER_IV_LENGTH( slot->attr.type, alg ) )
|
||||
{
|
||||
status = PSA_ERROR_INVALID_ARGUMENT;
|
||||
goto exit;
|
||||
|
Reference in New Issue
Block a user