1
0
mirror of https://github.com/bitcoinbook/bitcoinbook synced 2024-11-22 16:18:11 +00:00

sha256 diagram and updates

This commit is contained in:
Andreas M. Antonopoulos 2013-08-18 16:50:21 -07:00
parent 71a9fb520b
commit a37849a450
2 changed files with 5 additions and 1 deletions

View File

@ -47,6 +47,10 @@ Bitcoin is secured through computation and consensus. For a new block of transac
A hashing algorithm is a cryptographic function that takes an arbitrary length input (a text message or binary file), and produce a fixed-size output called the _hash_ or _digest_. It is trivial to verify the hash of any input, but it is computationally infeasible to predict or select an input to produce a desired hash. It's a one-way function, so it can easily work one way but is impossible to reverse.
[[figure_sha256_logical]]
.The Secure Hash Algorithm (SHA-256)
image::images/sha256-logical.png["SHA256"]
With SHA-256, the output is always 256 bits long, regardless of the size of the input. In the example below, we will use the Python interpreter to calculate the SHA256 hash of the phrase "I am Satoshi Nakamoto".
[[sha256_example1]]

BIN
images/sha256-logical.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB