mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-30 22:43:08 +03:00
Refactor lifetime checking to reflect split in location and persistence
Signed-off-by: Steven Cooreman <steven.cooreman@silabs.com>
This commit is contained in:
@ -1500,7 +1500,7 @@ static psa_status_t psa_validate_key_attributes(
|
||||
{
|
||||
psa_status_t status;
|
||||
|
||||
if( attributes->core.lifetime != PSA_KEY_LIFETIME_VOLATILE )
|
||||
if( ! PSA_KEY_LIFETIME_IS_VOLATILE( attributes->core.lifetime ) )
|
||||
{
|
||||
status = psa_validate_persistent_key_parameters(
|
||||
attributes->core.lifetime, attributes->core.id,
|
||||
@ -1660,7 +1660,7 @@ static psa_status_t psa_finish_key_creation(
|
||||
(void) driver;
|
||||
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_STORAGE_C)
|
||||
if( slot->attr.lifetime != PSA_KEY_LIFETIME_VOLATILE )
|
||||
if( ! PSA_KEY_LIFETIME_IS_VOLATILE( slot->attr.lifetime ) )
|
||||
{
|
||||
#if defined(MBEDTLS_PSA_CRYPTO_SE_C)
|
||||
if( driver != NULL )
|
||||
|
Reference in New Issue
Block a user