Skip to Content
Ethereum Smart Contract Development
book

Ethereum Smart Contract Development

by Mayukh Mukhopadhyay
February 2018
Intermediate to advanced
288 pages
6h 58m
English
Packt Publishing
Content preview from Ethereum Smart Contract Development

Understanding the hash function and the Merkle tree

Cryptography is the art and science of hiding a message. It is more of an art than a science. Science here just acts as a mere tool to transform an artistic imagination into a mathematical algorithm.

In this section, we will concentrate only on two specific concepts from this immensely vast subject, which will help us to understand the true essence of a blockchain. These are the hash function and Merkle tree. Please note that these are used for verifying integrity, rather than hiding anything.

Let's now understand what a hash function is and how it works. Figure 1.3 illustrates a hash function. As we can see in this figure, a hash function is a one-way mapping:

Figure 1.3: Hash function ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Building Games with Ethereum Smart Contracts: Intermediate Projects for Solidity Developers

Building Games with Ethereum Smart Contracts: Intermediate Projects for Solidity Developers

Kedar Iyer, Chris Dannen

Publisher Resources

ISBN: 9781788473040Supplemental Content