Skip to content

Commit 37d6ae7

Browse files
committed
crypto: Update the service for Mbed Crypto 3.x
Update Mbed OS's PSA Crypto service to work with Mbed Crypto 3.x. - psa_asymmetric_verify() is now called psa_verify_hash(). - psa_asymmetric_sign() is now called psa_sign_hash(). Compatibilty wrappers are provided via crypto_compat.h for source-level backwards compatibility.
1 parent cfc9e9f commit 37d6ae7

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

components/TARGET_PSA/services/crypto/COMPONENT_PSA_SRV_IPC/psa_crypto_spm.c

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1216,13 +1216,13 @@ psa_status_t psa_aead_abort(psa_aead_operation_t *operation)
12161216
return ipc_call(&operation->handle, &in_vec, 1, NULL, 0, true);
12171217
}
12181218

1219-
psa_status_t psa_asymmetric_sign(psa_key_handle_t handle,
1220-
psa_algorithm_t alg,
1221-
const uint8_t *hash,
1222-
size_t hash_length,
1223-
uint8_t *signature,
1224-
size_t signature_size,
1225-
size_t *signature_length)
1219+
psa_status_t psa_sign_hash(psa_key_handle_t handle,
1220+
psa_algorithm_t alg,
1221+
const uint8_t *hash,
1222+
size_t hash_length,
1223+
uint8_t *signature,
1224+
size_t signature_size,
1225+
size_t *signature_length)
12261226
{
12271227
psa_crypto_ipc_asymmetric_t psa_crypto_ipc = {
12281228
.func = PSA_ASYMMETRIC_SIGN,
@@ -1246,12 +1246,12 @@ psa_status_t psa_asymmetric_sign(psa_key_handle_t handle,
12461246
return (status);
12471247
}
12481248

1249-
psa_status_t psa_asymmetric_verify(psa_key_handle_t handle,
1250-
psa_algorithm_t alg,
1251-
const uint8_t *hash,
1252-
size_t hash_length,
1253-
const uint8_t *signature,
1254-
size_t signature_size)
1249+
psa_status_t psa_verify_hash(psa_key_handle_t handle,
1250+
psa_algorithm_t alg,
1251+
const uint8_t *hash,
1252+
size_t hash_length,
1253+
const uint8_t *signature,
1254+
size_t signature_size)
12551255
{
12561256
psa_crypto_ipc_asymmetric_t psa_crypto_ipc = {
12571257
.func = PSA_ASYMMETRIC_VERIFY,

0 commit comments

Comments
 (0)