rust-bitcoin / rust-bitcoin/rust-miniscript
It is basically impossible to get a LeafHash from a Tr descriptor to sign it
Open
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 426
- Forks
- 200
- Avg merge
- 7d 17h
- Merged PRs (30d)
- 8
Description
Unless I am crazy you need to iterate through the TapTree, convert the miniscripts to Script with Miniscript::encode, then call Script::taproot_leaf_hash on that.
Contributor 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.
Research direction
Start by tracing how a Tr descriptor stores and exposes its TapTree. Check how to iterate the TapTree, convert each miniscript with Miniscript::encode, and pass the resulting Script to Script::taproot_leaf_hash. Done means callers can obtain the relevant leaf hash from a Tr descriptor and the result is validated against the descriptor's tree.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- blockchain, cryptography
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100