Connecting Feeds...Syncing verified blockchain feeds (CoinGecko & RPC)...
BlockToolsHubCrypto Intelligence
Fundamentals8 min read

Cryptographic Hash Functions in Blockchains: SHA-256, Keccak-256, and Preimage Resistance

A developer's guide to one-way mathematical hash functions, collision resistance, and how addresses are generated from public keys.

Elena Rostova(Cryptographic Systems Researcher)
•
Updated 2025-02-23
Executive Summary

Deep dive into deterministic hash algorithms that power proof-of-work, address checksums, and block headers.

1. The Four Essential Cryptographic Properties

A cryptographic hash function maps arbitrary input data to a fixed-size byte string. To be secure for blockchains, it must be deterministic, quick to compute, pre-image resistant, and collision resistant.

Bitcoin utilizes double SHA-256 (SHA-256 applied twice). Ethereum utilizes Keccak-256 (the original proposal that became SHA-3 with subtle padding differences).

Interactive Tools Related to this Article

Audited Open SourceTrezor Safe 5

Secure your crypto offline with Trezor Safe 5

Full open-source firmware, secure element protection, and intuitive touchscreen control. Never store your seed phrase on a phone or laptop.

Affiliate partner: BlockToolsHub may earn a small referral commission at no additional cost to you.

Frequently Asked Questions

No. SHA-256 has never suffered a known collision in history. The search space (2^256) exceeds the number of atoms in the observable universe.