From 39574652ae0d9ed1b1558b150f1347727260b00b Mon Sep 17 00:00:00 2001 From: mohammad1603 Date: Fri, 1 Jun 2018 04:39:53 -0700 Subject: [PATCH] add else for not supported algorithm --- library/psa_crypto.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/library/psa_crypto.c b/library/psa_crypto.c index aaaa8a53c..beb5f559d 100755 --- a/library/psa_crypto.c +++ b/library/psa_crypto.c @@ -1669,7 +1669,11 @@ psa_status_t psa_aead_decrypt( psa_key_slot_t key, mbedtls_ccm_free( &ccm ); } - + else + { + return( PSA_ERROR_INVALID_ARGUMENT ); + } + *plaintext_length = ciphertext_length; return( PSA_SUCCESS ); }