Opcodes · crypto · enabled
OP_CHECKDATASIG (0xba)
Checks a signature over arbitrary message data (SHA-256 of msg), not the transaction. It lets contracts verify oracle-signed data. Accepts Schnorr signatures since May 2019.
Verified
- Stack in → out
- sig msg pubkey → ok
- Cost
- Base instruction cost 100 plus 26,000 per signature check, plus hashing cost for the message (2025 VM limits).
- Bitcoin status
- Not in Bitcoin (BTC)BTC has no data-signature opcode. In Tapscript, 0xba is OP_CHECKSIGADD (BIP-342), a different operation.
Example
<sig> <msg> <oracle_pubkey> OP_CHECKDATASIG Step through it opcode by opcode in Bitauth IDE, the in-browser BCH VM debugger.