1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-04-20 12:07:51 +03:00

Remove MBEDTLS_ECDH_COMPUTE_SHARED_ALT

Signed-off-by: Thomas Daubney <thomas.daubney@arm.com>
This commit is contained in:
Thomas Daubney 2024-07-18 12:13:09 +01:00
parent 51b90fb6b1
commit ce5ed8555c
3 changed files with 1 additions and 5 deletions

View File

@ -185,8 +185,7 @@
#endif #endif
#if defined(MBEDTLS_ECP_RESTARTABLE) && \ #if defined(MBEDTLS_ECP_RESTARTABLE) && \
( defined(MBEDTLS_ECDH_COMPUTE_SHARED_ALT) || \ ( defined(MBEDTLS_ECDSA_SIGN_ALT) || \
defined(MBEDTLS_ECDSA_SIGN_ALT) || \
defined(MBEDTLS_ECDSA_VERIFY_ALT) || \ defined(MBEDTLS_ECDSA_VERIFY_ALT) || \
defined(MBEDTLS_ECDSA_GENKEY_ALT) ) defined(MBEDTLS_ECDSA_GENKEY_ALT) )
#error "MBEDTLS_ECP_RESTARTABLE defined, but it cannot coexist with an alternative ECP implementation" #error "MBEDTLS_ECP_RESTARTABLE defined, but it cannot coexist with an alternative ECP implementation"

View File

@ -350,7 +350,6 @@
*/ */
//#define MBEDTLS_TIMING_ALT //#define MBEDTLS_TIMING_ALT
//#define MBEDTLS_ECDH_COMPUTE_SHARED_ALT
//#define MBEDTLS_ECDSA_VERIFY_ALT //#define MBEDTLS_ECDSA_VERIFY_ALT
//#define MBEDTLS_ECDSA_SIGN_ALT //#define MBEDTLS_ECDSA_SIGN_ALT
//#define MBEDTLS_ECDSA_GENKEY_ALT //#define MBEDTLS_ECDSA_GENKEY_ALT

View File

@ -84,7 +84,6 @@ int mbedtls_ecdh_gen_public(mbedtls_ecp_group *grp, mbedtls_mpi *d, mbedtls_ecp_
return ecdh_gen_public_restartable(grp, d, Q, f_rng, p_rng, NULL); return ecdh_gen_public_restartable(grp, d, Q, f_rng, p_rng, NULL);
} }
#if !defined(MBEDTLS_ECDH_COMPUTE_SHARED_ALT)
/* /*
* Compute shared secret (SEC1 3.3.1) * Compute shared secret (SEC1 3.3.1)
*/ */
@ -127,7 +126,6 @@ int mbedtls_ecdh_compute_shared(mbedtls_ecp_group *grp, mbedtls_mpi *z,
return ecdh_compute_shared_restartable(grp, z, Q, d, return ecdh_compute_shared_restartable(grp, z, Q, d,
f_rng, p_rng, NULL); f_rng, p_rng, NULL);
} }
#endif /* !MBEDTLS_ECDH_COMPUTE_SHARED_ALT */
static void ecdh_init_internal(mbedtls_ecdh_context_mbed *ctx) static void ecdh_init_internal(mbedtls_ecdh_context_mbed *ctx)
{ {