mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-04-16 08:42:50 +00:00
Use PSA_INIT with test that requires PSA
USE_PSA_INIT is for test code that doesn't use PSA functions when USE_PSA_CRYPTO is disabled. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
This commit is contained in:
parent
2e54854d16
commit
e2a77f21ea
@ -1867,7 +1867,7 @@ void pk_get_psa_attributes_opaque(int o_type_arg, int o_bits_arg,
|
|||||||
psa_key_usage_t usage = usage_arg;
|
psa_key_usage_t usage = usage_arg;
|
||||||
psa_key_usage_t expected_usage = expected_usage_arg;
|
psa_key_usage_t expected_usage = expected_usage_arg;
|
||||||
|
|
||||||
USE_PSA_INIT();
|
PSA_INIT();
|
||||||
|
|
||||||
psa_set_key_type(&attributes, o_type);
|
psa_set_key_type(&attributes, o_type);
|
||||||
psa_set_key_bits(&attributes, bits);
|
psa_set_key_bits(&attributes, bits);
|
||||||
@ -1899,6 +1899,6 @@ exit:
|
|||||||
mbedtls_pk_free(&pk);
|
mbedtls_pk_free(&pk);
|
||||||
psa_destroy_key(key_id);
|
psa_destroy_key(key_id);
|
||||||
psa_reset_key_attributes(&attributes);
|
psa_reset_key_attributes(&attributes);
|
||||||
USE_PSA_DONE();
|
PSA_DONE();
|
||||||
}
|
}
|
||||||
/* END_CASE */
|
/* END_CASE */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user