Module sapio_miniscript::miniscript
source · [−]Expand description
Abstract Syntax Tree
Defines a variety of data structures for describing Miniscript, a subset of Bitcoin Script which can be efficiently parsed and serialized from Script, and from which it is easy to extract data needed to construct witnesses.
Users of the library in general will only need to use the structures exposed from the top level of this module; however for people wanting to do advanced things, the submodules are public as well which provide visibility into the components of the AST.
Modules
Miniscript Analysis
AST Elements
Script Decoder
Miniscript Iterators
Lexer
Miscellaneous constraints imposed by Bitcoin. These constraints can be either Consensus or Policy (standardness) rules, for either Segwitv0 or Legacy scripts.
Satisfaction and Dissatisfaction
Miniscript Types Contains structures representing Miniscript types and utility functions Contains all the type checking rules for correctness and malleability Implemented as per rules on bitcoin.sipa.be/miniscript
Structs
Top-level script AST type
Enums
Bare ScriptContext To be used as raw script pubkeys In general, it is not recommended to use Bare descriptors as they as strongly limited by standardness policies.
Legacy ScriptContext
To be used as P2SH scripts
For creation of Bare scriptpubkeys, construct the Miniscript
under Bare
ScriptContext
Segwitv0 ScriptContext
Tap ScriptContext
Traits
The ScriptContext for Miniscript. Additional type information associated with miniscript that is used for carrying out checks that dependent on the context under which the script is used. For example, disallowing uncompressed keys in Segwit context