MCPcopy Create free account
hub / github.com/Bitcoin-ABC/bitcoin-abc / IsPayToScriptHash

Method IsPayToScriptHash

src/script/script.cpp:373–377  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

371}
372
373bool CScript::IsPayToScriptHash() const {
374 // Extra-fast test for pay-to-script-hash CScripts:
375 return (this->size() == 23 && (*this)[0] == OP_HASH160 &&
376 (*this)[1] == 0x14 && (*this)[22] == OP_EQUAL);
377}
378
379// A witness program is any valid CScript that consists of a 1-byte push opcode
380// followed by a data push between 2 and 40 bytes.

Callers 10

MutateTxSignFunction · 0.80
listunspentFunction · 0.80
VerifyScriptFunction · 0.80
SolverFunction · 0.80
RunMethod · 0.80
BOOST_AUTO_TEST_CASEFunction · 0.80
FUZZ_TARGETFunction · 0.80
FUZZ_TARGET_INITFunction · 0.80
FUZZ_TARGET_INITFunction · 0.80
ParsePrevoutsFunction · 0.80

Calls 1

sizeMethod · 0.45

Tested by 4

BOOST_AUTO_TEST_CASEFunction · 0.64
FUZZ_TARGETFunction · 0.64
FUZZ_TARGET_INITFunction · 0.64
FUZZ_TARGET_INITFunction · 0.64