remotesigner: generate MuSig2 nonces on signer
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 25/100
- Issue type
- Feature
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- go
- Domain
- backend, cryptography, security
Research direction
Read the linked sections in lnwallet/musig_session.go, lnwallet/rpcwallet/rpcwallet.go, and lnwallet/channel.go, plus issues #10705, #11529, and the remote-signing security model. Start by tracing nonce creation, RPC forwarding, and force-close reconstruction; then define signer-owned nonce persistence and replay behavior across the listed flows. Done means secret nonces stay on the signer, changed transcripts are rejected, and restart, force-close, and supported backup recovery cases are covered.
Written by the indexing model from the issue text.
Description
Description
Follow-up to #10705 and #11529.
The Taproot channel flow currently generates local MuSig2 nonces on the
watch-only node. RPCKeyRing.MuSig2CreateSession forwards the secret nonce
material through pregenerated_local_nonce:
Track moving nonce generation and secret nonce state to the signer. The
watch-only node should exchange public nonces and references to signer-owned
state.
Suggested scope
- Add a signer API for obtaining public nonces before the full signing session
is known, then using the corresponding nonce through an opaque handle or
equivalent signer-owned reference. - Update funding, commitment signing, cooperative close and reconnect paths to
use this API. Cover both classic RPC and the signer-initiated stream. - Reject caller-supplied secret nonces for keys covered by this isolation
contract, including through alternate signer API paths. - Define signer-side persistence or safe reconstruction across crashes and
restarts. Preserve exact commitment reconstruction after a lost response,
while rejecting reuse with a changed signing transcript. - Preserve force-close and static channel backup recovery. Define the rollout
for existing channels, wallet restore and lost or rolled-back signer state. - Update the remote-signing security model and document the resulting backup
requirements. Transaction validation and spending policy remain separate
work.
The nonce-to-transcript history in #11529 can remain useful for replay checks.
It stores fingerprints and transcript hashes, so secret nonce recovery still
needs its own design. Keep those replay checks while moving nonce ownership.
Test coverage
- The watch-only side receives public nonce material and opaque references;
secret nonce material stays on the signer. - Supplying secret nonce material through an old or alternate API cannot
bypass the new contract. - Reconnects, lost responses and signer restarts preserve the recorded
transcript and safe exact replay. - Changed transcripts fail before a partial signature is returned.
- Force-close and supported backup recovery work without secret nonces on the
watch-only node; unavailable signer state fails explicitly.
- Dominant language
- Go
- Stars
- 8.2k
- Forks
- 2.3k
- Avg merge
- 1d 11h
- Merged PRs (30d)
- 103
Getting set up
- Ships a Dockerfile or Docker Compose file
- Has a pull request template
- No contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from lightningnetwork/lnd
-
funding: failure logs print `<nil>` error and zero channel IDPossibly taken @litbot-9000 claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
lightningnetwork/lnd#11676 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 Half a day Newbie friendliness 85/100
lightningnetwork/lnd#11674 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
lightningnetwork/lnd#11672 ·
Maintainers usually reply within 1 day
-
test flake
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
lightningnetwork/lnd#11663 · 1 comment ·
Maintainers usually reply within 1 day
-
[flake]: lnwallet/test/bitcoind.TestLightningWalletBitcoindRPCPolling/spend_unconfirmed_outputsOpentest flake
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
lightningnetwork/lnd#11642 · 1 comment ·
Maintainers usually reply within 1 day
All issues in lightningnetwork/lnd
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
containers/gvisor-tap-vsock#796 ·
Maintainers usually reply within 2 days
-
external needs:triage
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
celestiaorg/celestia-node#5448 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 79/100
Maintainers usually reply within 1 day
-
[Bug]: Azure SAS signing uses local time instead of UTC, shifting validity window on non-UTC hostsPossibly taken @huanghaoyuanhhy claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
zilliztech/milvus-backup#1418 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
projectdiscovery/nuclei#8423 ·
Maintainers usually reply within 1 day