Skip to content

nassl: Add version 5.4.0 - #2729

Merged
luhenry merged 2 commits into
mainfrom
nassl
Oct 8, 2026
Merged

luhenry merged 2 commits into
mainfrom
nassl

Conversation

@luhenry

@luhenry luhenry commented Oct 5, 2026 •

Copy link
Copy Markdown
Member

Compiles nassl's C extension against its own statically-linked, from-source OpenSSL (a legacy OpenSSL_1_0_2e build and a modern OpenSSL_1_1_1w build) and zlib. Upstream publishes no riscv64 wheel.

Mirrors upstream's build_wheels.yml.

Differs from upstream

  • CIBW_BEFORE_ALL_LINUX installs the full perl package - the riscv64 image's minimal perl lacks FindBin/lib, which OpenSSL's Configure needs.

Matrix: cp310-cp314, matching upstream's own non-abi3 wheel set; no cp314t, which upstream does not build either.

Testing

  • same as upstream

License: OK

Patches

  • 0001-build_config-add-a-riscv64-target.patch - To upstream. Without it, build_config.py's platform detection has no riscv64 branch and silently targets OpenSSL's Configure at linux-x86_64. Reproduces off riscv64 (verified by monkeypatching platform.machine()).

CI pending.

nassl statically links its own from-source OpenSSL (a legacy OpenSSL_1_0_2e
build and a modern OpenSSL_1_1_1w build) and zlib rather than the system
libraries, selected per-platform in build_config.py. That file has no
riscv64 branch at all: its 64-bit Linux detection only special-cases
aarch64, so riscv64 silently fell through to the x86_64 target.

Patch build_config.py to add a riscv64 platform: the modern build uses
OpenSSL's own "linux64-riscv64" Configure target (1.1.1w carries no
riscv64 assembly at all, added only in the 3.x series, so this is a plain
portable-C build with none of the large-shared-object asm relocation
pitfalls a newer OpenSSL's riscv64 asm can hit); the legacy build's pinned
1.0.2e predates riscv64 entirely and falls back to "linux-generic64",
mirroring how it already special-cases OSX_ARM64 two lines above.

Workflow mirrors upstream's own build_wheels.yml/build_wheels_linux_aarch64.yml
(cibuildwheel driving invoke's build.deps/build.nassl tasks), narrowed to
riscv64, with one extra CIBW_BEFORE_ALL_LINUX step installing the riscv64
manylinux image's full perl package (its minimal perl-interpreter lacks
FindBin/lib, which OpenSSL's Configure needs). Matrix is cp310..cp314,
matching upstream's own non-abi3 wheel set; no cp314t, which upstream
does not build either.
luhenry added a commit that referenced this pull request Oct 5, 2026
@github-actions

github-actions Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor
PR Preview Action v1.8.1

QR code for preview link

🚀 View preview at
https://riseproject-dev.github.io/python-wheels/pr-preview/pr-2729/

Built to branch gh-pages at 2026-10-05 18:58 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

CI run https://github.com/riseproject-dev/python-wheels/actions/runs/37336888859
was red on 3 of 5 interpreter legs, from two independent, non-riscv64 causes:

- cp313/cp314 both failed tests/cert_chain_verifier_test.py::test_valid_certificate_chain
  with OpenSSL error 20 ("unable to get local issuer certificate"). That test fetches
  www.github.com's live leaf cert at test time and hardcodes a 2018-era Sectigo
  intermediate to chain it against tests/mozilla.pem; GitHub's real issuing CA has
  since rotated (now "Sectigo Public Server Authentication CA DV E36"), so the
  hardcoded intermediate no longer matches the live leaf's issuer on any platform
  today, not just riscv64. No newer upstream release fixes this past the 5.4.0 tag,
  and nassl's Kali Linux packaging has hit the same test break before (error 10
  instead of 20, same live-fetch-vs-hardcoded-cert root cause). Pinning today's
  correct intermediate would only move the next CA rotation's break further out,
  so skip the test instead (0002).

- cp311 timed out (~1018s) and cp310/cp312 hung to the 90-minute job ceiling, all
  fetching the same https://www.zlib.net/fossils/zlib-1.2.13.tar.gz within the same
  few seconds, while cp313/cp314 fetched it in seconds -- a thundering-herd/
  under-provisioned-server pattern on zlib.net's CDN-less legacy archive, not a
  one-off single-job flake. Fetch zlib from GitHub's tag archive instead (0003),
  which this same file already does for OpenSSL, carries the identical tree, and
  needs no src_path change (GitHub's vX.Y.Z-tag archive already extracts to
  zlib-1.2.13, same convention build-cvxopt.yml already relies on for SuiteSparse).

Both patches verified to apply together, in sequence, against a clean 5.4.0 checkout.
luhenry added a commit that referenced this pull request Oct 5, 2026
Both failures in PR #2729's first riscv64 CI run were non-riscv64-specific:
a stale hardcoded CA intermediate in nassl's own cert-chain test (GitHub has
rotated its issuing CA since the test was written), and zlib.net's CDN-less
fossils archive choking under this CI matrix's simultaneous fetches. Notes
updated with the full root-cause evidence; CI re-run queued, not yet green.
@luhenry
luhenry marked this pull request as ready for review October 5, 2026 19:13
@luhenry
luhenry merged commit abd82c5 into main Oct 8, 2026
13 checks passed
@luhenry
luhenry deleted the nassl branch October 8, 2026 14:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant