BIP 141 describes a new kind of authentication template called Pay-to-Witness-Script-Hash (P2WSH).

This template moves challenge and response scripts to witness data. The last element of witness data (serialized "witness script") corresponds to the challenge script that used to be encoded within an output. This script can use any operation, including non-push-data operations.

However, the nature of the first chunk of witness data is less clear. Is this section just deserialized and executed, as with an input script, or is this section just an array of bytes? If the former, can non-push-data operations be performed? Or do operations need to be restricted to push-data only?

In other words, will I be able to encode operations such as OP_DROP, etc into witness data outside of the witness script?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.