Build the crypto binding on rust:1.98-alpine by adopting the paramant-core with bindgen 0.72 - #329
Merged
Merged
Conversation
Bumps rust from 1.95-alpine to 1.98-alpine. --- updated-dependencies: - dependency-name: rust dependency-version: 1.98-alpine dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com>
…-core with bindgen 0.72 Dependabot's rust 1.95-alpine -> 1.98-alpine bump (#313) fails in the paramant-core-binding stage with E0609 "no field alg_version on type &OQS_SIG". The base image is not at fault: Alpine 3.24 ships libclang 22, under which bindgen 0.71 (pulled in by oqs-sys 0.11.0 and older) emits the forward-declared OQS_SIG as an opaque struct. Rustc version is irrelevant, paramant-core's rust-toolchain.toml pins 1.95.0 anyway. paramant-core#24 fixes that at the source (oqs 0.11.0, oqs-sys patched to the upstream commit with bindgen 0.72, musl CI job on this same rust:1.98-alpine digest), so this takes the base bump from #313 and moves both paramant-core pins, PARAMANT_CORE_COMMIT in the Dockerfile and PARAMANT_CORE_SHA in the crypto-suite job, to that commit. The Dockerfile comment that documented the 1.95 pin now documents the actual cause instead. Verified locally: `docker build` of relay/ with this Dockerfile completes (binding stage finishes `cargo build --locked --release`, final image builds); in the runtime image `require('@paramant/core')` loads the musl binding and ML-DSA-65 keygen/sign/verify round-trips; the relay crypto suite (144 tests) passes on the host against the binding built from paramant-core b90b3c5. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XJk2nCLCLmi3F71qkCUn7N
This was referenced Sep 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Supersedes #313 (the rust 1.95-alpine -> 1.98-alpine bump; its commit is cherry-picked here unchanged). Depends on Apolloccrypt/paramant-core#24, which this PR pins by commit.
Why #313 failed
Not the Rust version: paramant-core's
rust-toolchain.tomlpins 1.95.0 and the failure reproduces with that toolchain inside the 1.98 image.rust:1.98-alpineis Alpine 3.24 with libclang 22.1.3, and bindgen 0.71 (whatoqs-sys<= 0.11.0 requires) emits the forward-declaredOQS_SIGas an opaque{ _address: u8 }under libclang 22, henceE0609: no field alg_version on type &OQS_SIG. Two-line reproduction and the bindgen/libclang matrix are in paramant-core#24.Change
relay/Dockerfile: baserust:1.98-alpine@sha256:a10e64dd...(from build(deps): bump rust from 1.95-alpine to 1.98-alpine in /relay #313);PARAMANT_CORE_COMMITdc454d4->b90b3c5(paramant-core#24: oqs 0.11.0 / liboqs 0.13.0, oqs-sys patched to bindgen 0.72); the comment block that documented the 1.95 pin now documents the cause..github/workflows/test.yml:PARAMANT_CORE_SHA45a3d35->b90b3c5, so the relay crypto-suite gate runs against the same paramant-core the image ships.No relay source changes.
Verification (local, NUC, Docker 29.6.1)
docker buildofrelay/with this Dockerfile,--no-cache: binding stageFinished release [optimized] target(s) in 1m 57s, full image built.require('@paramant/core')loads the musl binding;mldsaKeygen/mldsaSign/mldsaVerifyround-trip (signature 3309 bytes, verifytrue).b90b3c5(node --test crypto/*.test.js): 144 pass, 0 fail.musl build - paramant-core-nodeon this exactrust:1.98-alpinedigest, and the ML-DSA-65 / ML-KEM-768 KAT suites.Byte-compatibility
Algorithm identifiers (
ML-DSA-65,ML-KEM-768,SPHINCS+-SHA2-128f-simple,Falcon-512) are unchanged between liboqs 0.12.0 and 0.13.0; the 50 @noble-anchored ML-DSA-65 KAT vectors and the relay crypto suite verify unchanged. No wire-format or version-id changes.Not done here
b90b3c5stays fetchable only while the branch exists).🤖 Generated with Claude Code
https://claude.ai/code/session_01XJk2nCLCLmi3F71qkCUn7N