Repository navigation
Conversation
This was referenced Oct 25, 2026
Sjors
force-pushed
the
2026/10/taproot-anti-exfil
branch
from
October 25, 2026 09:52
d0a2712 to
68ec8de
Compare
Specify the additive two-round single-signer protocol, provisional proprietary PSBT input fields, transcript validation and interruption handling. Include independent Python reference arithmetic and reproducible vectors.
Sjors
force-pushed
the
2026/10/taproot-anti-exfil
branch
from
October 25, 2026 15:01
68ec8de to
75e3f23
Compare
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.
This draft specifies an interactive anti-exfiltration protocol for single-signer BIP340 signatures and provisional PSBT input fields. A malicious device can return a valid transaction signature while encoding secrets in its nonce. The honest host commits to a random scalar, records the device's original nonce point, reveals its scalar, and verifies both ordinary signature validity and the prescribed additive nonce relation.
The construction follows Scheme 6 in Pieter Wuille's overview and Stepan Snigirev's nonce-blinding/PSBT proposal. The contribution is a precise Taproot profile, interoperable fields, independent vectors, and experimental implementations across the host, bridge, and devices. It does not claim a new formal security proof.
Scope and trust model
ae, for PSBTv0 and PSBTv2. Canonical encodings, input-only placement, consistent rounds, and no new untargeted signatures are required. Field allocation could move to a separate BIP.The two asymmetric models are an honest host with a malicious device, and an honest device with a malicious host. The host includes wallet software, coordinators, bridges, drivers and their dependencies. It may delegate proof checking and retained session state to a checked trusted component; duplicate verification by every component is not required. Independent checks within the host provide defense in depth, without isolating a compromised host process. An honest device must still protect its signing key and authorize the transaction on its display. A malicious device cannot be trusted to enforce its own preflight checks.
The nonce property concerns verified on-chain signatures for a fixed request. Exposing the private transcript or unrelated device output creates additional channels; timing, selective failures, malicious seed generation and physical leakage remain separate limitations. Deterministic stateless recovery does not itself provide fresh signer-side synthetic nonce randomness.
ECDSA, general sign-to-contract, script-path signing, MuSig2 and FROST are outside this draft. Existing BitBox02/Jade ECDSA anti-klepto deployments and earlier libsecp proposals are acknowledged in Markdown footnotes.
The informative MuSig2 section explains a conditional argument for blocking adaptive nonce grinding by privately collecting and freezing contributions. It requires fresh independent honest entropy hidden from the colluding malicious subset, fixed session parameters, retained original full nonce pairs and partial-signature checks. Selective aborts and public transcripts remain separate channels. BIP327's unforgeability proof does not establish this anti-exfil property; MuSig2 extensions remain outside the specification.
BIP-EXFIL/hostandBIP-EXFIL/nonceare placeholders. Number assignment requires a coordinated domain update and regenerated vectors across every implementation.Companion implementations
The draft remains one commit, Draft interactive anti-exfiltration for BIP340 signatures, with no implementation build dependencies.
Companion descriptions identify dependencies by PR and commit subject. Firmware implementations need not consume the standalone libsecp PR: existing custom-nonce APIs can implement the same protocol. These proposals do not claim released-device support.
HWI's verified-response sanitization is implemented and locally validated, including actual Jade/Coldcard driver decoding of device-controlled PSBT bytes. This addresses additional PSBT export exposure; Core already copies only verified signatures. Ledger's invocation-wide native PSBT preflight alignment is being validated as conformance and robustness work. It is not a change to the nonce construction or a claim that malicious firmware can be constrained by its own preflight.
Validation
The eight reference vectors regenerate byte for byte, with no nonce, wire-format, reference-code or vector changes from these clarifications. Independent checks cover all 15 applicable 32-byte official BIP340 cases, the eight vectors through compiled native libsecp commit/sign/verify APIs, scalar/point boundaries, changed transcripts and invalid signatures, infinity, and injected exceptional nonce failures.
Markdown footnotes/local references, repository link-format and table checks, and whitespace checks pass. Specialist cryptographic review remains necessary, including malicious-host concurrency and cross-protocol interactions. Transport acceptance and completed-PSBT export rules are tightened without claiming a new cryptographic result.