From 7962284f78d9b86c4e5e382be5dbab77890a8e82 Mon Sep 17 00:00:00 2001 From: Gilles Peskine Date: Wed, 24 Feb 2021 21:56:22 +0100 Subject: [PATCH] Mention psa_hash_compute in the documentation of psa_{sign,verify}_hash Signed-off-by: Gilles Peskine --- include/psa/crypto.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/include/psa/crypto.h b/include/psa/crypto.h index d1609f8bb..5f9c5a8a2 100644 --- a/include/psa/crypto.h +++ b/include/psa/crypto.h @@ -2847,7 +2847,8 @@ psa_status_t psa_aead_abort(psa_aead_operation_t *operation); * * Note that to perform a hash-and-sign signature algorithm, you must * first calculate the hash by calling psa_hash_setup(), psa_hash_update() - * and psa_hash_finish(). Then pass the resulting hash as the \p hash + * and psa_hash_finish(), or alternatively by calling psa_hash_compute(). + * Then pass the resulting hash as the \p hash * parameter to this function. You can use #PSA_ALG_SIGN_GET_HASH(\p alg) * to determine the hash algorithm to use. * @@ -2898,7 +2899,8 @@ psa_status_t psa_sign_hash(mbedtls_svc_key_id_t key, * * Note that to perform a hash-and-sign signature algorithm, you must * first calculate the hash by calling psa_hash_setup(), psa_hash_update() - * and psa_hash_finish(). Then pass the resulting hash as the \p hash + * and psa_hash_finish(), or alternatively by calling psa_hash_compute(). + * Then pass the resulting hash as the \p hash * parameter to this function. You can use #PSA_ALG_SIGN_GET_HASH(\p alg) * to determine the hash algorithm to use. *