Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

secp256k1 test failure on machines with OpenSSL 3.0.x installed #6180

Closed
daira opened this issue Sep 26, 2022 · 4 comments · Fixed by #6182
Closed

secp256k1 test failure on machines with OpenSSL 3.0.x installed #6180

daira opened this issue Sep 26, 2022 · 4 comments · Fixed by #6182
Labels
A-dependencies Area: Dependencies

Comments

@daira
Copy link
Contributor

daira commented Sep 26, 2022

Describe the issue

make -C src/secp256k1 check fails on my machine. (This is run by qa/zcash/full_test_suite.py.)

Can you reliably reproduce the issue?

Yes:

  1. Check out 34f0a97 which is current zcash master.
  2. zcutil/build.sh
  3. make -C src/secp256k1 check

Expected behaviour

The secp256k1 tests should pass.

Actual behaviour + errors

  CCLD     exhaustive_tests
clang-14: warning: argument unused during compilation: '-static-libstdc++' [-Wunused-command-line-argument]
make  check-TESTS
make[1]: Entering directory '/home/daira/zecc/zcash.master/src/secp256k1'
make[2]: Entering directory '/home/daira/zecc/zcash.master/src/secp256k1'
./build-aux/test-driver: line 112: 632834 Aborted                 "$@" >> "$log_file" 2>&1
FAIL: tests
PASS: exhaustive_tests
============================================================================
Testsuite summary for libsecp256k1 0.1
============================================================================
# TOTAL: 2
# PASS:  1
# SKIP:  0
# XFAIL: 0
# FAIL:  1
# XPASS: 0
# ERROR: 0
============================================================================
See ./test-suite.log
============================================================================
make[2]: *** [Makefile:1287: test-suite.log] Error 1
make[2]: Leaving directory '/home/daira/zecc/zcash.master/src/secp256k1'
make[1]: *** [Makefile:1395: check-TESTS] Error 2
make[1]: Leaving directory '/home/daira/zecc/zcash.master/src/secp256k1'
make: *** [Makefile:1613: check-am] Error 2
make: Leaving directory '/home/daira/zecc/zcash.master/src/secp256k1'

daira@katava:/home/daira/zecc/zcash.master$ cat src/secp256k1/test-suite.log 
========================================
   libsecp256k1 0.1: ./test-suite.log
========================================

# TOTAL: 2
# PASS:  1
# SKIP:  0
# XFAIL: 0
# FAIL:  1
# XPASS: 0
# ERROR: 0

.. contents:: :depth: 2

FAIL: tests
===========

test count = 64
random seed = 7e869b10c369a59b3ab8ad74115b2b05
Failure 10 on 30 23 02 03 40 b5 80 02 1c a1 b1 ff fb ff 00 00 00 10 f8 ff ff ff ef ff ff 00 ec ff fb ff ff ff ff ff 01 00 00 
src/tests.c:4947: test condition failed: ret == 0
FAIL tests (exit status: 134)

The version of Zcash you were using:

Zcash Daemon version v5.2.0-34f0a973c

Machine specs:

  • OS name + version: Debian 11 (Bullseye)
  • CPU: Intel(R) Core(TM) i7-6800K CPU @ 3.40GHz
  • RAM: 96 MiB (~50% free)
  • Disk size: 150 GB available
  • Disk Type (HD/SDD): the git checkout is on an SDD, the filesystem root is HD
  • Linux kernel version (uname -a): Linux katava 5.19.0-1-amd64 #1 SMP PREEMPT_DYNAMIC Debian 5.19.6-1 (2022-09-01) x86_64 GNU/Linux
  • Compiler version (gcc --version): gcc (Debian 12.2.0-2) 12.2.0
  • Linker version (ld -v): GNU ld (GNU Binutils for Debian) 2.38.90.20220713
  • Assembler version (as --version): GNU assembler (GNU Binutils for Debian) 2.38.90.20220713
@daira daira added the A-dependencies Area: Dependencies label Sep 26, 2022
@daira
Copy link
Contributor Author

daira commented Sep 26, 2022

I think this is likely to be bitcoin-core/secp256k1#984 . My installed version of OpenSSL is:

$ openssl version
OpenSSL 3.0.5 5 Jul 2022 (Library: OpenSSL 3.0.5 5 Jul 2022)

Upstream removed support for testing libsecp256k1 against OpenSSL in bitcoin-core/secp256k1#983 .

@str4d
Copy link
Contributor

str4d commented Sep 27, 2022

This looks like a duplicate of #6115. Both should be addressed by one of the libsecp256k1 update issues; I'll figure out which.

@str4d
Copy link
Contributor

str4d commented Sep 27, 2022

This issue would be addressed by #5840, but that is blocked on #5838 which in turn is blocked on migrating the Rust crates to secp256k1 0.22. I will test locally whether a future subtree update will be affected if I manually backport that particular change early.

@daira daira changed the title secp256k1 test failure secp256k1 test failure on machines with OpenSSL 3.0.x installed Sep 27, 2022
@daira
Copy link
Contributor Author

daira commented Sep 27, 2022

Building zcashd with CONFIGURE_FLAGS="--disable-openssl-tests" seems to be sufficient to fix this (it roughly replicates the effect of bitcoin-core/secp256k1#983).

str4d added a commit to str4d/zcash that referenced this issue Sep 27, 2022
This is a temporary fix until we can backport the removal of these tests
in bitcoin-core/secp256k1#983.

Closes zcash#6180.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-dependencies Area: Dependencies
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants