summaryrefslogtreecommitdiff
path: root/bip-0141.mediawiki
diff options
context:
space:
mode:
authorMark "Murch" Erhardt <murch@murch.one>2024-04-23 15:25:33 -0400
committerGitHub <noreply@github.com>2024-04-23 15:25:33 -0400
commit4731fc407f0c320bd5bcd727bfa9203f55123afe (patch)
treed5fca824f8508f05224a7f9058830f5f8787fd32 /bip-0141.mediawiki
parenteb7a787de0eef5ce4596865034926b4e50603a4a (diff)
parent608d5dc95f2ddcee32758fe73de6d68b99021e39 (diff)
Merge pull request #487 from Christewart/patch-2
Specify which 1 byte push op codes are valid
Diffstat (limited to 'bip-0141.mediawiki')
-rw-r--r--bip-0141.mediawiki2
1 files changed, 1 insertions, 1 deletions
diff --git a/bip-0141.mediawiki b/bip-0141.mediawiki
index efdd9c9..2247ef6 100644
--- a/bip-0141.mediawiki
+++ b/bip-0141.mediawiki
@@ -83,7 +83,7 @@ If all transactions in a block do not have witness data, the commitment is optio
=== Witness program ===
-A <code>scriptPubKey</code> (or <code>redeemScript</code> as defined in BIP16/P2SH) that consists of a 1-byte push opcode (for 0 to 16) followed by a data push between 2 and 40 bytes gets a new special meaning. The value of the first push is called the "version byte". The following byte vector pushed is called the "witness program".
+A <code>scriptPubKey</code> (or <code>redeemScript</code> as defined in BIP16/P2SH) that consists of a select subset of opcodes (<code>OP_0,OP_1,OP_2,...,OP_16</code>) followed by a data push between 2 and 40 bytes gets a new special meaning. The value of the first push is called the "version byte". The following byte vector pushed is called the "witness program".
There are two cases in which witness validation logic are triggered. Each case determines the location of the witness version byte and program, as well as the form of the scriptSig:
# Triggered by a <code>scriptPubKey</code> that is exactly a push of a version byte, plus a push of a witness program. The scriptSig must be exactly empty or validation fails. (''"native witness program"'')