From 8d1160cf57120300c623e0ebdeaa5fc0f282d040 Mon Sep 17 00:00:00 2001 From: Konstantinos Margaritis Date: Sun, 17 Sep 2023 09:26:29 +0000 Subject: [PATCH] remove OpenSSL dependency, use own SHA512 hash --- crypto/ed25519-donna/Makefile | 4 ++-- crypto/ed25519-donna/src/test.c | 7 ++----- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/crypto/ed25519-donna/Makefile b/crypto/ed25519-donna/Makefile index 0c68b4a9..3477736f 100644 --- a/crypto/ed25519-donna/Makefile +++ b/crypto/ed25519-donna/Makefile @@ -8,13 +8,13 @@ CROSSOBJCOPY = powerpc64le-linux-gnu-objcopy CROSSLD = powerpc64le-linux-gnu-ld #compiler flags here -CFLAGS = -DED25519_SVP64 -DED25519_TEST -g3 -O -Wall -I../../media/pypowersim_wrapper -I/usr/include/python3.7m +CFLAGS = -DED25519_SVP64 -DED25519_TEST -DED25519_REFHASH -g3 -O -Wall -I../../media/pypowersim_wrapper -I/usr/include/python3.7m # assembler flags here ASFLAGS= -mlibresoc -mregnames -Isrc #linker flags here -LDFLAGS = -Wall -pthread -lpython3.7m -lssl -lcrypto +LDFLAGS = -Wall -pthread -lpython3.7m SRCDIR = src BINDIR = bin diff --git a/crypto/ed25519-donna/src/test.c b/crypto/ed25519-donna/src/test.c index 8af3afc9..98230020 100644 --- a/crypto/ed25519-donna/src/test.c +++ b/crypto/ed25519-donna/src/test.c @@ -107,13 +107,8 @@ default amd64-64-24k / amd64-51-32k behaviour /* batch test */ -#ifndef ED25519_SVP64 #define test_batch_count 64 #define test_batch_rounds 96 -#else -#define test_batch_count 1 -#define test_batch_rounds 1 -#endif typedef enum batch_test_t { batch_no_errors = 0, @@ -266,7 +261,9 @@ test_main(void) { int main(void) { +#ifndef ED25519_SVP64 test_main(); +#endif test_batch(); return 0; } -- 2.30.2