The script_flags harness aims to test that our script verification flags are soft-forks (i.e. applying flags can only tighten the verification rules and not widen them). SigVersion::WITNESS_V0 and SigVersion::TAPSCRIPT scripts are currently not covered by this test, as fuzzers are blocked from e.g. creating a valid taproot script path spend commitment.
This PR:
- Moves the taproot commitment and witness script hash checks to
BaseSignatureChecker(real impl inGenericTransactionSignatureChecker) - Introduces a second script flags harness
script_flags_mockedwhich uses aBaseSignatureCheckermock, unblocking fuzzers from reaching segwit v{0,1} interpreter code (as well as paths relating to valid signatures)