aboutsummaryrefslogtreecommitdiff
path: root/projects/bitcoin-core
diff options
context:
space:
mode:
authorGuido Vranken <guidovranken@users.noreply.github.com>2021-06-22 05:21:23 +0200
committerGitHub <noreply@github.com>2021-06-21 20:21:23 -0700
commitd217819bd7f8dcf18cb1af4ebe521417be091b6f (patch)
tree0687510360c7a7f1779fa2378963813077dec4e7 /projects/bitcoin-core
parent3d878248acc0054761d98a0ef9a96587e64d4388 (diff)
downloadoss-fuzz-d217819bd7f8dcf18cb1af4ebe521417be091b6f.tar.gz
[bitcoin-core] libsecp256k1: Compare against schnorr_fun, implement ECDH (#5958)
Diffstat (limited to 'projects/bitcoin-core')
-rwxr-xr-xprojects/bitcoin-core/build_cryptofuzz.sh23
1 files changed, 21 insertions, 2 deletions
diff --git a/projects/bitcoin-core/build_cryptofuzz.sh b/projects/bitcoin-core/build_cryptofuzz.sh
index a827dc0a7..1ee7d0a48 100755
--- a/projects/bitcoin-core/build_cryptofuzz.sh
+++ b/projects/bitcoin-core/build_cryptofuzz.sh
@@ -40,11 +40,21 @@ function build_libsecp256k1() {
make clean
fi
+ SECP256K1_CONFIGURE_PARAMS="
+ --enable-static
+ --disable-tests
+ --disable-benchmark
+ --disable-exhaustive-tests
+ --enable-module-recovery
+ --enable-experimental
+ --enable-module-schnorrsig
+ --enable-module-ecdh"
+
if [[ $CFLAGS = *sanitize=memory* ]]
then
- ./configure --enable-static --disable-tests --disable-benchmark --disable-exhaustive-tests --enable-module-recovery --enable-experimental --enable-module-schnorrsig --with-asm=no "$@"
+ ./configure $SECP256K1_CONFIGURE_PARAMS --with-asm=no "$@"
else
- ./configure --enable-static --disable-tests --disable-benchmark --disable-exhaustive-tests --enable-module-recovery --enable-experimental --enable-module-schnorrsig "$@"
+ ./configure $SECP256K1_CONFIGURE_PARAMS "$@"
fi
make
@@ -97,6 +107,7 @@ echo -n 'ECDSA_Verify,' >>extra_options.h
echo -n 'ECDSA_Recover,' >>extra_options.h
echo -n 'Schnorr_Sign,' >>extra_options.h
echo -n 'Schnorr_Verify,' >>extra_options.h
+echo -n 'ECDH_Derive,' >>extra_options.h
echo -n 'BignumCalc_Mod_2Exp256 ' >>extra_options.h
echo -n '--curves=secp256k1 ' >>extra_options.h
echo -n '--digests=NULL,SHA1,SHA256,SHA512,RIPEMD160,SHA3-256,SIPHASH64 ' >>extra_options.h
@@ -110,6 +121,14 @@ cd ../trezor/
make -B -j$(nproc)
cd ../botan/
make -B -j$(nproc)
+cd ../schnorr_fun/
+export CXXFLAGS="$CXXFLAGS -DCRYPTOFUZZ_SCHNORR_FUN"
+if [[ $CFLAGS != *-m32* ]]
+then
+ make
+else
+ make -f Makefile.i386
+fi
cd ../../
# Build with 3 configurations of libsecp256k1