psa_crypto: allow asymmetric encryption/decryption also with opaque keys
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
This commit is contained in:
parent
f202c2968b
commit
5bb454aace
1 changed files with 2 additions and 2 deletions
|
@ -3080,7 +3080,7 @@ psa_status_t psa_asymmetric_encrypt(mbedtls_svc_key_id_t key,
|
|||
return PSA_ERROR_INVALID_ARGUMENT;
|
||||
}
|
||||
|
||||
status = psa_get_and_lock_transparent_key_slot_with_policy(
|
||||
status = psa_get_and_lock_key_slot_with_policy(
|
||||
key, &slot, PSA_KEY_USAGE_ENCRYPT, alg);
|
||||
if (status != PSA_SUCCESS) {
|
||||
return status;
|
||||
|
@ -3132,7 +3132,7 @@ psa_status_t psa_asymmetric_decrypt(mbedtls_svc_key_id_t key,
|
|||
return PSA_ERROR_INVALID_ARGUMENT;
|
||||
}
|
||||
|
||||
status = psa_get_and_lock_transparent_key_slot_with_policy(
|
||||
status = psa_get_and_lock_key_slot_with_policy(
|
||||
key, &slot, PSA_KEY_USAGE_DECRYPT, alg);
|
||||
if (status != PSA_SUCCESS) {
|
||||
return status;
|
||||
|
|
Loading…
Reference in a new issue