January 2019
Beginner to intermediate
372 pages
11h 17m
English
The block header stores the metadata of the block, and its size is 80 bytes, as shown in the previous table. It stores version information with which you can identify the block. hashPrevBlock stores a 256-bit hash value of the previous block, which links the blocks and ensures the integrity of the blockchain. hashMerkleRoot is the hash digest of the transactions and ensures the integrity of transactions.
The time, difficulty bits, and nonce fields are related to the Proof of Work consensus algorithm:
|
Field |
Purpose |
Size |
|
Version |
Block version |
4 bytes |
|
hashPrevBlock |
256-bit hash of the previous block header |
32 bytes |
|
hashMerkleRoot |
256-bit hash based on all of the transactions in the block |
32 bytes ... |