For scriptpath spending, a new syntax is added that allows specifying the contents of a binary tree. For example, { {B,C} , {D,E} } specifies the following tree:
A tree can be specified as an optional second parameter to the descriptor template we used before. For example if Alice wants to be able to spend via keypath, but she also wants to allow Bob, Carol, Dan, and Edmond spend via a scriptpath that generates an audit trail for her (but not for third-party chain surveillance), Alice can use the following descriptor:
tr( <a_key> , { {pk(<b_key>),pk(<c_key>)} , {pk(<d_key>),pk(<e_key>)} )
The above features are all that’s required to use descriptors for taproot, but PR #22051 notes that there are still some things missing that could be added to make descriptors better at completely describing expected policies:
Voided keypaths: some users may want to prevent usage of keypath spending in order to force scriptpath spending. That can be done now by using an unspendable key as the first parameter to tr(), but it’d be nice to allow wallets to store this preference in the descriptor itself and have it compute a privacy-preserving unspendable keypath.
Tapscript multisig: for legacy and v0 segwit, the multi() and sortedmulti() descriptors support the OP_CHECKMULTISIG opcode. To allow batch verification in taproot, script-based multisig is handled a bit differently in tapscript, so tr() descriptors currently need to specify any necessary multisig opcodes via a raw() script. Updated versions of multi() andsortedmulti() for tapscripts would be nice to have.
MuSig-based multisignatures: earlier in this article, we described Alice, Bob, and Carol manually aggregating their keys in order to use a tr() descriptor. Ideally, there would be a function that allows them to specify something like tr(musig(<a_key>, <b_key>, <c_key>)) so that they could retain all the original key information and use it to populate fields in the PSBTs they use to coordinate signing.
Timelocks, hashlocks, and pointlocks: these powerful constructions used in LN, DLCs , coinswaps , and many other protocols can currently only be described via the raw() function. Adding support for them directly to descriptors is possible, but it may be the case that support will be added instead through descriptor’s sibling project, miniscript . Integration of miniscript into Bitcoin Core is still an ongoing project, but we expect its innovations to spread to other wallets in the same way that tools like PSBTs and descriptors already have.
Wallets don’t need to implement descriptors in order to start using taproot, but those that do will give themselves a better foundation for using more advanced taproot features later.
Releases and release candidates
New releases and release candidates for popular Bitcoin infrastructure projects. Please consider upgrading to new releases or helping to test release candidates.
LND 0.13.1-beta.rc1 is a maintenance release with minor improvements and bug fixes for features introduced in 0.13.0-beta.
Notable code and documentation changes
Notable changes this week in Bitcoin Core , C-Lightning , Eclair , LND , Rust-Lightning , libsecp256k1 , Hardware Wallet Interface (HWI) , Rust Bitcoin , BTCPay Server , Bitcoin Improvement Proposals (BIPs) , and Lightning BOLTs .
Bitcoin Core #19651 allows the wallet key manager to update existing descriptors . This allows wallet users to edit labels, extend descriptor ranges, reactivate inactive descriptors, and make other updates using the importdescriptors wallet RPC.
C-Lightning #4610 adds an –experimental-accept-extra-tlv-types command-line option which allows users to specify a list of even-numbered TLV types that lightningd should pass through for plugins to handle. Previously, lightningd considered all unknown evenly-typed TLV messages to be invalid. This change allows for plugins to define and handle their own custom TLV types unknown to lightningd.
Eclair #1854 adds support for decoding and logging of warning messages sent from peers like C-Lightning that have recently implemented warning message types.
BIPs #1137 adds BIP86 , which suggests a key derivation scheme for single key P2TR outputs. The BIP was summarized in last week’s newsletter .
BIPs #1134 updates BIP155 to indicate that the sendaddr2 P2P feature negotiation message should be sent any time a software program understands version 2 addr messages , including in cases where the program doesn’t necessarily want to receive addr messages.
Find the original post here.
Please subscribe to the Bitcoin Optech newsletter directly to receive this content straight to your inbox every month.