I was reading about how Bitcoin works from Satoshi's original paper. I had a query while going through the 7th paragraph. What is the difference between Root Hash and Block Hash? Isn't the block hash same as the hash of the root of its Merkle Tree? I have studied Merkle tree and understand how it works.
2 Answers
First, all transactions are hashed along a Merkle tree. The root of that tree is the Merkle root.
Then the block header is created with 6 fields: version number, the hash of the previous block, the time, the difficulty, and the Merkle root computed in the previous step.
Then that block header (which contains the Merkle root) is hashed, resulting in the block hash.
-
-
@VaradBhatnagar You can help the site by marking answers as accepted if they are correct and address the question so that the question does not remain as "unanswered".– WilltechMar 9, 2018 at 11:55
-
Isn't the block hash same as the hash of the root of its Merkle Tree?
No
What is the difference between Root Hash and Block Hash?
The root hash is a 'Merkle Tree' of all the transactions in the block.
The block hash is a separate hash derived from data in the block header. Data in the block header includes the Merkle Tree hash, but also includes:
- the block version number
- the 256-bit hash of the previous block header
- the current timestamp expressed as seconds since 1970-01-01T00:00 UTC
- the current target in compact format
- a random 32-bit 'nonce'.