bitcoin-dev
Making OP_CODESEPARATOR and FindAndDelete in non-segwit scripts non-standard
Posted on: November 16, 2017 09:27 UTC
The proposal to remove OP_CODESEPARATOR and FindAndDelete from non-segwit scripts has been put forth by Johnson Lau in the bitcoin-dev mailing list.
Mark Friedenbach objects to this proposal as it could potentially destroy value and has only been done in the past either because of lack of understanding or because the features were fundamentally insecure. However, if the proposal is implemented, all blocks before the softfork block can be whitelisted to completely remove FindAndDelete() from the consensus code later. The conservative approach would be to leave the code until the last non-segwit P2SH UTXO from before the soft fork block has been spent, but this may not happen if a private key is lost. Transactions containing these OP-codes could still be considered valid after making them non-standard and removing the code, but some miners may not verify them. A variant of this scenario is proposed where miners put up a large deposit if they mine such legacy transactions, but can lose it if someone else finds the transaction invalid.