miniscript::Node::Satisfy

Produce a witness for this script, if possible and given the information available in the context. The non-malleable satisfaction is guaranteed to be valid if it exists, and ValidSatisfaction() is true. If IsSane() holds, this satisfaction is guaranteed to succeed in case the node's conditions are satisfied (private keys and hash preimages available, locktimes satisfied).

Synopsis

Declared in <script/miniscript.h>

template<typename Ctx>
Availability
Satisfy(
    Ctx const& ctx,
    std::vector<std::vector<unsigned char>>& stack,
    bool nonmalleable = true) const;

Return Value

The availability of the requested satisfaction.

Parameters

NameDescription
ctxContext providing the satisfaction data (keys, preimages, timelocks).
stackOutput witness stack that receives the produced satisfaction.
nonmalleableWhether to require a nonmalleable, signature-backed satisfaction.