2

Many OPCODES like OP_AND, OP_CAT, OP_SUBSTR are disabled as described in https://en.bitcoin.it/wiki/Script. Although, with Bitcoin Core 0.10.0 Gavin Andresen proposed "any Script" in P2SH transactions to be relayed/mined: enter image description here I'm still unsure if this applies disabled opcodes. I've come across a Mainnet coinbase transaction with disabled "OP_AND" opcode here, and a Testnet transaction here. I'm very curios if P2SH transactions with disabled opcodes in the redeem script relayed and mined on the BTC Mainnet.

1 Answer 1

2

On that wiki link you posted it states:

If any opcode marked as disabled is present in a script, it must abort and fail.

An attempted UTXO spend with a failed script will not be relayed between nodes running Bitcoin Core (and other major implementations) and certainly won't be included in a mined block.

The mainnet coinbase transaction you link to includes an OP_AND in an input scriptSig. But input(s) in a coinbase transaction are ignored as it is mining new Bitcoins and is not spending from any output from another transaction.

The testnet transaction you link to includes an OP_AND in an output scriptPubKey. It hasn't been spent and can't be spent because there is no scriptSig that can spend from it.

BIP-Tapscript (BIP 342) proposes to make disabled opcodes like OP_AND OP_SUCCESSx which would mean that the Tapscript would automatically succeed if the opcode is encountered. This is so that new opcode functionality could potentially be introduced in a future soft fork without breaking backwards compatibility. But Taproot/Tapscript is not yet activated on the network at the time of writing (October 2020).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.