mirror of
https://github.com/bitcoin/bips.git
synced 2025-05-19 12:08:05 +00:00
Moved diagrams to hashes section.
This commit is contained in:
parent
0ea5ba232d
commit
0ab3b3eb0c
@ -73,8 +73,6 @@ The serialization has the following structure:
|
||||
| The block number or timestamp until which the transaction is locked
|
||||
|}
|
||||
|
||||
<img src=bip-codeshark-segwit-peer-services/witnesstx.png></img>
|
||||
|
||||
Parsers supporting this BIP will be able to distinguish between the old serialization format (without the witnesses) and this one. The marker byte is set to zero so that this structure will never parse as a valid transaction in a parser that does not support this BIP. If parsing were to succeeded, such a transaction would contain no inputs and a single output.
|
||||
|
||||
If all witnesses are empty, the old serialization format should be used.
|
||||
@ -112,10 +110,15 @@ implicitly, every transaction and block have a witness, old ones just
|
||||
have empty ones.
|
||||
|
||||
=== Hashes ===
|
||||
Transaction hashes used in the transaction merkle tree and txin outpoints is always computed on the old non-witness
|
||||
serialization. A new hash including the witness data is added that is
|
||||
computed from the witness-serialization (this means that transactions
|
||||
with an empty witness have witness hash equal to normal hash).
|
||||
Transaction hashes used in the transaction merkle tree and txin outpoints are always computed using the old non-witness
|
||||
serialization.
|
||||
|
||||
Support for a new hash including the witness data is added that is
|
||||
computed from the new witness serialization. (Note that transactions
|
||||
with an empty witness always use the old serialization,
|
||||
and therefore, they have witness hash equal to normal hash.)
|
||||
|
||||
<img src=bip-codeshark-segwit-peer-services/witnesstx.png></img>
|
||||
|
||||
== Credits ==
|
||||
Special thanks to Gregory Maxwell for originating many of the ideas in this BIP and Luke-Jr for figuring out how to deploy this as a soft fork.
|
||||
|
Loading…
x
Reference in New Issue
Block a user