From 7807bf740499fb785d687879c6ee85f0af80373a Mon Sep 17 00:00:00 2001 From: David Brown Date: Tue, 9 Feb 2021 16:28:23 -0700 Subject: [PATCH] Use proper conditional for software DES When converting definitions to use the new PSA defines, one erroneously was conditionalized on the WANT macro instead of on the BUILTIN macro. Signed-off-by: David Brown --- library/psa_crypto.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library/psa_crypto.c b/library/psa_crypto.c index 18f98c036..9b3305f55 100644 --- a/library/psa_crypto.c +++ b/library/psa_crypto.c @@ -5063,7 +5063,7 @@ exit: return( status ); } -#if defined(PSA_WANT_KEY_TYPE_DES) +#if defined(MBEDTLS_PSA_BUILTIN_KEY_TYPE_DES) static void psa_des_set_key_parity( uint8_t *data, size_t data_size ) { if( data_size >= 8 ) @@ -5073,7 +5073,7 @@ static void psa_des_set_key_parity( uint8_t *data, size_t data_size ) if( data_size >= 24 ) mbedtls_des_key_set_parity( data + 16 ); } -#endif /* PSA_WANT_KEY_TYPE_DES */ +#endif /* MBEDTLS_PSA_BUILTIN_KEY_TYPE_DES */ static psa_status_t psa_generate_derived_key_internal( psa_key_slot_t *slot,