mirror of
https://github.com/bitcoin/bips.git
synced 2025-02-24 07:28:03 +01:00
BIP118: tweak wording around 1-byte pubkey
This commit is contained in:
parent
420dc42f0e
commit
d616d5492b
1 changed files with 2 additions and 2 deletions
|
@ -60,14 +60,14 @@ These keys are termed '''BIP 118 public keys'''.
|
|||
|
||||
==== Rules for signature opcodes ====
|
||||
|
||||
The [[bip-0342.mediawiki|BIP 342]] rules for signature opcodes are modified by removing keys with the first byte <code>0x01</code> and length of 1-byte or 33-bytes from the list of unknown public key types, and adding the following rule prior to the handling of unknown public key types:
|
||||
The [[bip-0342.mediawiki|BIP 342]] rules for signature opcodes are modified by removing keys with the first byte <code>0x01</code> and length of either 1-byte or 33-bytes from the list of unknown public key types, and adding the following rule prior to the handling of unknown public key types:
|
||||
|
||||
* If the public key is the single byte <code>0x01</code>, or if the public key is 33 bytes and the first byte of the public key is <code>0x01</code>, it is considered to be a BIP 118 public key:
|
||||
** If the signature is not the empty vector, the signature is validated according to the [[bip-0341.mediawiki|BIP 341]] signing validation rules with the public key, allowable <code>hash_type</code> values, and transaction digest modified as defined below.
|
||||
|
||||
==== Public key ====
|
||||
|
||||
To convert a 1-byte BIP 118 public key for use with [[bip-0340.mediawiki|BIP 340]], use the 32-byte taproot internal key, <code>p</code>, as defined in [[bip-0341.mediawiki|BIP 341]].
|
||||
To convert the 1-byte BIP 118 public key for use with [[bip-0340.mediawiki|BIP 340]], use the 32-byte taproot internal key, <code>p</code>, as defined in [[bip-0341.mediawiki|BIP 341]].
|
||||
|
||||
To convert a 33-byte BIP 118 public key for use with [[bip-0340.mediawiki|BIP 340]], remove the <code>0x01</code> prefix and use the remaining 32 bytes.
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue