mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-01-31 09:32:55 +00:00
Replace PSA_KEY_AGREEMENT_MAX_SHARED_SECRET_SIZE with PSA_RAW_KEY_AGREEMENT_OUTPUT_MAX_SIZE in psa_key_agreement_internal().
Signed-off-by: Aditya Deshpande <aditya.deshpande@arm.com>
This commit is contained in:
parent
39e08d4094
commit
2f7fd76d91
@ -5735,7 +5735,6 @@ psa_status_t psa_key_derivation_input_key(
|
|||||||
/****************************************************************/
|
/****************************************************************/
|
||||||
/* Key agreement */
|
/* Key agreement */
|
||||||
/****************************************************************/
|
/****************************************************************/
|
||||||
#define PSA_KEY_AGREEMENT_MAX_SHARED_SECRET_SIZE MBEDTLS_ECP_MAX_BYTES
|
|
||||||
|
|
||||||
psa_status_t psa_key_agreement_raw_builtin( const psa_key_attributes_t *attributes,
|
psa_status_t psa_key_agreement_raw_builtin( const psa_key_attributes_t *attributes,
|
||||||
const uint8_t *key_buffer,
|
const uint8_t *key_buffer,
|
||||||
@ -5809,7 +5808,7 @@ static psa_status_t psa_key_agreement_internal( psa_key_derivation_operation_t *
|
|||||||
size_t peer_key_length )
|
size_t peer_key_length )
|
||||||
{
|
{
|
||||||
psa_status_t status;
|
psa_status_t status;
|
||||||
uint8_t shared_secret[PSA_KEY_AGREEMENT_MAX_SHARED_SECRET_SIZE];
|
uint8_t shared_secret[PSA_RAW_KEY_AGREEMENT_OUTPUT_MAX_SIZE];
|
||||||
size_t shared_secret_length = 0;
|
size_t shared_secret_length = 0;
|
||||||
psa_algorithm_t ka_alg = PSA_ALG_KEY_AGREEMENT_GET_BASE( operation->alg );
|
psa_algorithm_t ka_alg = PSA_ALG_KEY_AGREEMENT_GET_BASE( operation->alg );
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user