Blockchain – Understanding Block Header Format

block-headerblocksleveldbrlp

Does anyone understand what each element of a block header represents? I have an example block header represented here:

[

cd7bd64fba4cc782fe5474d3640882afece5887180591e72f80ce6916cf73526,

1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347,

f927a40c8b7f6e07c5af7fa2155b4864a4112b13,

30430d24554454b251003be3d027dea94397bf45cd34c6a06abcfec662242046,

56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421,

56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421,

00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000,

3b32b8463f,

1780,

1388,

"",

55ba9f2d,

"Geth/v1.0.0/linux/go1.4.2",

437fa41b15c73334a947241ec885423a487d4401a0c3ec7c30550c1e039bccd7,

c5317acb884dfc49,

]

What do each of these elements represent? Is there an official source that also definitively says what each of these values mean?

Best Answer

  • Parent hash: This is the Keccak 256-bit hash of the parent (previous) block's header.

• Ommers hash: This is the Keccak 256-bit hash of the list of ommers (or uncles) blocks included in the block.

• The beneficiary: The beneficiary field contains the 160-bit address of the recipient that will receive the mining reward once the block is successfully mined.

• State root: The state root field contains the Keccak 256-bit hash of the root node of the state trie. It is calculated once all transactions have been processed and finalized.

• Transactions root: The transaction root is the Keccak 256-bit hash of the root node of the transaction trie. The transaction trie represents the list of transactions included in the block.

• Receipts root: The receipts root is the Keccak 256-bit hash of the root node of the transaction receipt trie. This trie is composed of receipts of all transactions included in the block. Transaction receipts are generated after each transaction is processed and contain useful post-transaction information. More details on transaction receipts are provided in the next section.

• Logs bloom: The logs bloom is a bloom filter that is composed of the logger address and log topics from the log entry of each transaction receipt of the included transaction list in the block. Logging is explained in detail in the next section.

  • Logs bloom: The logs bloom is a bloom filter that is composed of the logger address and log topics from the log entry of each transaction receipt of the included transaction list in the block. Logging is explained in detail in the next section.

• Difficulty: The difficulty level of the current block.

• Number: The total number of all previous blocks; the genesis block is block zero.

• Gas limit: This field contains the value that represents the limit set on the gas consumption per block.

• Gas used: This field contains the total gas consumed by the transactions included in the block.

• Timestamp: The timestamp is the epoch Unix time of the time of block initialization.

  • Extra data: The extra data field can be used to store arbitrary data related to the block. Only up to 32 bytes are allowed in this field.

• Mixhash: The mixhash field contains a 256-bit hash that, once combined with the nonce, is used to prove that adequate computational effort (Proof of Work, or PoW) has been spent in order to create this block.

• Nonce: Nonce is a 64-bit hash (a number) that is used to prove, in combination with the mixhash field, that adequate computational effort (PoW) has been spent in order to create this block.

enter image description here

Related Topic