This section covers the history and security aspects of SHA 256. It is also very helpful for visualizing and understanding the avalanche effect. Even a minor difference, like a single character change in text, can lead to significantly different hash outputs.
SHA-2 (Secure Hash Algorithm 2) is a set of cryptographic hash functions designed by the United States National Security Agency (NSA) and first published in 2001. It would be really helpful if you understood hashing and cryptographic hashing to appreciate this topic.
SHA256 is complex. Watch this video for an appreciation:
Even a small change in the message will (with overwhelming probability) result in a mostly different hash, due to the avalanche effect. For example, adding a period to the end of the following sentence changes almost half (111 out of 224) of the bits in the hash:
SHA224("The quick brown fox jumps over the lazy dog") 0x 730e109bd7a8a32b1cb9d9a09aa2325d2430587ddbc0c38bad911525 SHA224("The quick brown fox jumps over the lazy dog.") 0x 619cba8e8e05826e9b8c519c0a5c68f4fb653e8a3d8aa04bb2c8cd4c
Source: Computer Science Wiki, https://computersciencewiki.org/index.php/SHA256 This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 License.