From 8c683f92847a1f0a191041e95980b87e79dacc92 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20P=C3=A9gouri=C3=A9-Gonnard?= Date: Wed, 5 Jan 2022 10:09:49 +0100 Subject: [PATCH] Enable ECDSA in ecc-heap.sh MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Clearly the intention was to enable it, as ECDSA_C was defined, but the benchmark also requires SHA-256 for ECDSA. Also, specify "ecdh ecdsa" when invoking the benchmark program, in order to avoid spurious output about SHA-256. Signed-off-by: Manuel Pégourié-Gonnard --- scripts/ecc-heap.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/ecc-heap.sh b/scripts/ecc-heap.sh index 71c33f855..d985fa20c 100755 --- a/scripts/ecc-heap.sh +++ b/scripts/ecc-heap.sh @@ -58,6 +58,8 @@ cat << EOF >$CONFIG_H #define MBEDTLS_ASN1_PARSE_C #define MBEDTLS_ASN1_WRITE_C #define MBEDTLS_ECDSA_C +#define MBEDTLS_SHA256_C // ECDSA benchmark needs it +#define MBEDTLS_SHA224_C // SHA256 requires this for now #define MBEDTLS_ECDH_C #define MBEDTLS_ECP_DP_SECP192R1_ENABLED @@ -80,7 +82,7 @@ for F in 0 1; do make benchmark >/dev/null 2>&1 echo "fixed point optim = $F, max window size = $W" echo "--------------------------------------------" - programs/test/benchmark + programs/test/benchmark ecdh ecdsa done done