test(frost): real-crypto multi-process libp2p e2e — shape-B + distributed DKG#4110
Open
mswilkison wants to merge 1 commit into
Open
Conversation
…uted DKG Two separate-process (RFC-21 "shape B") real-crypto e2es over real libp2p, each re-execing the test binary as N worker processes that each link libfrost_tbtc: - shape-B (roast_shapeb_libp2p_multiproc_e2e): dealer DKG run once in a bootstrap subprocess, the encrypted key group copied into each worker's own state dir; every worker drives the ROAST interactive-signing runner over real libp2p and independently aggregates the same BIP-340 signature (n winners, vs the shared- engine in-process shape-A's one). Proves per-node engine/state isolation + the libp2p outer framing for the runner + ROAST + transport seam. - distributed-DKG (roast_distributed_dkg_libp2p_multiproc_e2e): every worker runs the real distributed FROST DKG (part1/2/3) over libp2p, with round-2 per-recipient secret shares sealed via secp256k1 ECDH + AES-256-GCM (cleartext round-2 over a broadcast bus would let any node reconstruct a peer's share), so each node holds ONLY its own key package; then threshold-signs via the stateless low-level path. Closes the dealer-DKG custody gap end to end. Both run green standalone and under the full -run TestRealCgoInteractiveSigning cgo gate with KEEP_CORE_FROST_REQUIRE_CGO=true (skips forbidden). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
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.
Stacks on the FROST/ROAST readiness branch (#3866). Adds two separate-process ("shape B") real-crypto e2es over real libp2p, complementing the in-process shape-A multinode test. Each re-execs the test binary as N worker processes that each link
libfrost_tbtc.What's added
roast_shapeb_libp2p_multiproc_e2e_…): dealer DKG run once in a bootstrap subprocess, the encrypted key group copied into each worker's own state dir; every worker drives the ROAST interactive-signing runner over real libp2p and independently aggregates the same BIP-340 signature (n winners, vs the shared-engine shape-A's one). Covers per-node engine/state isolation + the libp2p outer framing for the runner + ROAST + transport seam.roast_distributed_dkg_libp2p_multiproc_e2e_…): every worker runs the real distributed FROST DKG (part1/2/3) over libp2p, with round-2 per-recipient secret shares sealed via secp256k1 ECDH + AES-256-GCM (cleartext round-2 over a broadcast bus would let any node sumf_i(j)and reconstruct a peer's share), so each node holds only its own key package; then threshold-signs via the stateless low-level path. Closes the dealer-DKG key-custody gap end to end.Verification
Both green standalone (stable across repeated runs) and under the full cgo gate, linking
libfrost_tbtcbuilt from the pinned signer ref (ci/frost-signer-pin.env=6e3718ba0, unchanged):All 6 real-crypto tests pass together on this branch (4 shape-A + shape-B + distributed-DKG).
CI
The
frost-cgo-integrationgate already exercises both new tests — its-run 'TestRealCgoInteractiveSigning'matches them by prefix, and the pinned crate already exports thedkg_part1/2/3+ low-level sign FFI they use. No workflow change needed. (Heads-up: these are multi-process + gossipsub tests; robust locally via retransmission + warmup, but mesh-convergence time varies — if shape-B ever flakes on a slow runner, move it to a non-blocking job.)Note
Building the distributed-DKG test confirmed
dkg_part1/2/3interoperate over the transport — but the node's DKG path (executeTBTCSignerFROSTDKG) still uses the dealerRunDKGWithSeed. Wiring distributed DKG into the node remains the readiness-gate-blocking work.🤖 Generated with Claude Code