Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simple taproot channels v2 #3005

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from
Draft

Simple taproot channels v2 #3005

wants to merge 2 commits into from

Conversation

sstone
Copy link
Member

@sstone sstone commented Feb 10, 2025

This is a simpler alternative to #2868: musig2 nonce exchange has been moved into the interactive tx session, and become much simpler as there open_v2/accept_v2, splice_ or rbfmessages remain unchanged. Channel re-establishment logic becomes a bit more complex, which is mitigated by storing and re-sending the lastcommit_sig` message if needed.

@sstone sstone requested a review from t-bast February 10, 2025 16:10
@sstone sstone force-pushed the simple-taproot-channels-v2 branch 5 times, most recently from a83fb4c to c00154f Compare February 18, 2025 19:49
@sstone sstone force-pushed the simple-taproot-channels-v2 branch 3 times, most recently from caac917 to 3374a21 Compare February 25, 2025 21:50
@sstone sstone force-pushed the simple-taproot-channels-v2 branch 2 times, most recently from a380030 to a7348f8 Compare March 5, 2025 09:17
sstone added 2 commits March 5, 2025 12:13
We add a new specific commitment format for taproot channels, and high-level methods for creating and spending taproot channel transactions.
This commit implements:
  - feature bits for simple taproot channels
  - TLV extensions for funding/closing wire messages
  - modifications to how we handle channel funding, splicing and mutual closing
  - changes to the commitment structures

The v1 channel establishment protocol is modified to include nonces for creating and signing taproot transactions. This is bascially the original simple taproot proposal, which does
not cover dual-funding, splices and rbf.

We assume that simple taproot channels depends on the simple close protocol, which we extend to include musig2 nonces.

Dual-funding, splices and rbf are supported by extending the interactive tx session protocol to include musig2 nonce, which are attached to the `tx_complete` message.
There are 2 types of nonces:
- "funding nonces", which are used to sign a new funding tx that spends the current funding tx (splice, rbf).
- "commit nonces", which are used to sign the commit tx that is one of the outputs of the interactive session.

"funding nonces" can be randomly generated on-the-fly: either the interactive session will fail, and they can be forgotten, or it will succeed and we'll get a new, fully signed funding tx.
"commit nonces" can be deterministically generated.

This make nonce exchange simpler to reason about:
- when we send `tx_complete`, we know exactly what the funding tx and commit tx will be (so the funding tx id can be mixed in the nonce generation process).
- dual funding, splice and rbf message do not need to be modified

Channel re-establishment becomes a bit more complex, as one node could still be waiting for signatures while the other has completed the splice workflow, but it
can be mitigated by storing the last sent commit_sig and re-sending it again if needed.
@sstone sstone force-pushed the simple-taproot-channels-v2 branch from a7348f8 to ba4c11c Compare March 5, 2025 15:52
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