3 ms·
Your intuition is correct. The Merkle root (hash of the root node) is only useful as a summary of the whole hash tree structure. The clever idea here is not tha
by dsukhin 7y ago
Your intuition is correct. The Merkle root (hash of the root node) is only useful as a summary of the whole hash tree structure. The clever idea here is not that the tree itself is encoded in the Merkle root but rather that the root is a unique id of a whole unique tree and all the data. Having the hash tree available (which is much smaller than the data itself), you can validate any leaf node's (1) integrity and (2) membership in the set much quicker than a full scan by calculating the tree.
Merkle trees are also used in Bitcoin and similar protocols to find if a transaction is present in a block. This may be a another useful link to help understand the concepts: https://hackernoon.com/merkle-trees-181cb4bc30b4 https://hackernoon.com/merkle-trees-181cb4bc30b4