1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-07-28 00:21:48 +03:00

Fix psa_pake_get_implicit_key() state & add corresponding tests in ecjpake_rounds()

Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
This commit is contained in:
Neil Armstrong
2022-06-15 11:32:11 +02:00
parent ed40782628
commit 1e855601ca
2 changed files with 40 additions and 18 deletions

View File

@ -660,8 +660,8 @@ psa_status_t psa_pake_get_implicit_key(psa_pake_operation_t *operation,
if( operation->alg == 0 ||
operation->state != PSA_PAKE_STATE_READY ||
( operation->input_step != PSA_PAKE_STEP_DERIVE &&
operation->output_step != PSA_PAKE_STEP_DERIVE ) )
operation->input_step != PSA_PAKE_STEP_DERIVE ||
operation->output_step != PSA_PAKE_STEP_DERIVE )
return( PSA_ERROR_BAD_STATE );
#if defined(MBEDTLS_PSA_BUILTIN_ALG_JPAKE)