ElementsProject / libwally-core

Useful primitives for wallets
Other
281 stars 135 forks source link

descriptor: Implement wallet-policies BIP #369

Closed jgriffiths closed 11 months ago

jgriffiths commented 1 year ago

See https://github.com/bitcoin/bips/pull/1389 for details of wallet policies.

Note wally implements the /* extension to support non-BIP44 wallets such as Blockstream Green. Additionally, we do not limit allowable policies to the whitelist in the linked BIP. We allow all valid descriptors where the solved cardinality is either 1 or 2.

Includes some extra functionality that is useful for validating descriptors/policies, primarily the ability to iterate and query the keys in the parsed expression.