PQAI #1: Keccak-256, the Hash Foundation of Ethereum in the Post-Quantum, Post-AI Era
- Core Viewpoint: The Ethereum Foundation recommends Keccak-256 as the standard hash function for its post-quantum hash-based cryptography, as advances in SNARK technology have made the cost of proving standard hashes no longer a bottleneck, making security rather than performance the decisive factor.
- Key Elements:
- Breakthroughs in SNARK technology have enabled standard hash proving speeds of over 500,000 per second, eliminating the performance trade-offs that previously necessitated ZK-friendly hashes (such as Poseidon).
- Keccak-256 has nearly two decades of cryptanalysis accumulation, with practical collision attacks reaching only 5 out of 24 rounds, a security margin significantly superior to SHA2-256 (which has been attacked to 38 out of 64 rounds).
- Keccak-256 is based on a sponge construction, provably indistinguishable from a random oracle (under both classical and quantum adversaries), avoiding the length extension issues that SHA2-256 faces due to its Merkle–Damgård structure.
- Keccak-256 was chosen over SHA3-256 because the former is already an in-protocol opcode, avoiding the introduction of a nearly identical function differing only in padding bits, thereby reducing integration risk.
- Impact on clients is minimal: EL clients require no new hash, and signature verification reuses existing implementations; CL clients are advised in the long term to migrate SSZ merkleization from SHA2-256 to Keccak-256.
- The Poseidon family was excluded due to its reduced-round versions being continuously broken and its cryptanalysis not yet mature; BLAKE3 has a sparse cryptanalysis record and its working mode lacks security proofs.
Original article from the Ethereum Foundation blog, by:Kev Wedderburn
Compiled by | SuDiXia@Odaily
This decision is the product of years of work, with numerous researchers and engineers both inside and outside the EF contributing ideas, proof breakthroughs, and feedback that made this step possible today—including the authors of Binius, the authors of WHIR, Angus Gruen, and Lev Soukhanov for his contributions to GKR, Benedikt Bünz, Ron Rothblum, and William Wang for their contributions to Flock, Justin Thaler and Quang Dao for their sumcheck innovations, the various zkEVM teams that shaped the current version of leanVM, and many others in the cryptography community. This list is longer than this post itself.
Special thanks to everyone within the EF who contributed to this article: Alex Hicks, Antonio Sanso, Benedikt Wagner, Cody Gunton, Derek Sorensen, Dmitry Khovratovich, Emile, George Kadianakis, Gottfried Herold, Han Jian, Ignacio Hagopian, Justin Drake, Tau, Thomas Coratger, and Vitalik Buterin.
We recommend Keccak-256 as the hash function used for Ethereum's hash-based cryptography.
Keccak-256 has nearly two decades of cryptanalysis behind it, with ample security margin. Ethereum already uses it for addresses and execution layer state; continuing to bet on it means Ethereum does not need to add a third general-purpose hash to the protocol beyond SHA2-256.
Since we need more than one hash function, we use a family of symmetric primitives derived from the Keccak-f[1600] permutation: including Keccak-256 for standard hashing, the sponge object Keccak-duplex for Fiat-Shamir transforms, and SHAKE256 for pseudorandom bit generation and key derivation.
What Changed: Performance Is No Longer the Deciding Factor
Once Ethereum shifts to hash-based cryptography, the protocol's security reduces to the hash function itself: break the hash, and everything else breaks. The same hash must also perform well in three quite different environments:
- On CPU. Clients run it natively for signing and verification, hashing the state tree, and deriving addresses.
- In zkVM. Signatures, blobs, and recursive aggregation all run in leanVM, the zkVM we will use in the protocol. The proof cost per hash must be low enough not to become an aggregation bottleneck—today this means proving roughly 500,000 hashes per second on EIP-7870-class hardware, corresponding to roughly 1,000 attestations per second, sufficient to cover one committee of the consensus layer.
- Inside the EVM. Contracts compute hashes to verify signatures, check on-chain storage proofs, or support some niche application that requires hashing. What matters here is gas cost, typically meaning a dedicated opcode or precompile.
For years, performance in zkVM was the bottleneck: traditional hashes were too expensive to prove, so the industry's default assumption was that Ethereum's post-quantum signatures would need a ZK-friendly hash, such as Poseidon, trading more thoroughly studied security for proof speed. It was precisely for this reason that we spent years trying to harden Poseidon's cryptanalysis.
This trade-off has disappeared, because SNARKs can now efficiently handle standard hashes. Binary field SNARKs (Binius, Flock) and GKR-based provers now prove standard hashes at speeds that meet or even significantly exceed the target of 500,000 per second. Proof performance can no longer distinguish standard hashes from algebraic hashes, so security has become the deciding factor.
The security bar is high because this choice is hard to reverse. This hash will protect Ethereum's value for decades, so we want the largest possible body of public cryptanalysis, and a security margin wide enough that breaking it would require entirely new cryptanalytic methods. All else being equal among candidates, we prefer to reuse what Ethereum already has, to reduce ecosystem disruption, because every new primitive must be implemented, optimized, audited, and fuzz-tested in every client, zkVM, and SDK.
Narrowing the Field
We compared five candidates: Poseidon/Poseidon2, BLAKE3, BLAKE2, SHA2-256, and Keccak-256.
ZK-Friendly Hashes: Poseidon and Poseidon2
Poseidon (2019) and Poseidon2 (2023) were designed to be efficiently provable in SNARKs over prime fields, an advantage that binary field SNARKs have largely erased.
In 2022, Bariant et al. used a small trick—skipping two full rounds at nearly zero cost—to show that the designers' analysis was overly optimistic. In addition, the Poseidon cryptanalysis initiative launched by the EF in November 2024 has continued to produce new attacks against reduced-round versions of both (Sanso and Vitto 2025, Bak et al. 2026). The full-round versions of both remain unbroken, but since traditional hashes are now fast enough to prove, there is no reason to wait for cryptanalysis to mature slowly.
We note that Poseidon and Poseidon2 are actually two entirely different hash functions. However, our conclusion is the same for both.
High-Speed Hashes: BLAKE3 and BLAKE2
BLAKE3 (2020) is the fastest traditional hash we examined: on a 16 vCPU machine, provers have already reached roughly 2.2 million BLAKE3 compressions per second (SNARK.fast Flock Challenge).
But it both modifies BLAKE2's round function and reduces the number of rounds from 10 to 7. As a result, cryptanalytic attacks against BLAKE2 and BLAKE3 cannot be applied to each other, and BLAKE3's cryptanalysis record is sparse. In addition, BLAKE3's mode of operation has no security proof, and its underlying block cipher is known to have distinguishers on a considerable number of rounds.
BLAKE2 (2012) is more thoroughly studied, although there are still fewer than 10 publicly known cryptanalytic attacks, with the best attack against the hash itself reaching 2.5 rounds (BLAKE2). It is still considered secure (and fast), and Ethereum exposes its compression function (blake2f) through the EIP-152 precompile. We ultimately did not choose BLAKE2 because the remaining candidates have significantly more cryptanalysis behind them, and performance is sufficient.
The Incumbents: SHA2-256 and Keccak-256
This leaves the two hashes Ethereum already uses.
SHA2-256 (2001) is used by the consensus layer's (CL) SSZ, and is the execution layer's (EL) 0x02 precompile, and is in turn used by the current deposit contract.
It is fast natively, especially benefiting from SHA-NI on x86. But practical collision attacks have reached 35 of its 64 rounds, with the best collision attack reaching 38 rounds, more than half the total (Li et al. 2026, Zhang et al. 2026, Goldreich 2026).
The security proofs of hash-based signatures, and the Fiat-Shamir step in the SNARGs that aggregate them, both treat the hash as a random oracle. But SHA2-256 uses the Merkle-Damgård construction, and length extension alone is enough to distinguish it from a random oracle.
Therefore, schemes built on it require extra care: for example, SLH-DSA-SHA2 uses HMAC and MGF1 in some functions. The random oracle issue can of course be patched, but requiring every protocol built on SHA2-256 to take extra care here is not desirable.
Keccak-256 (2008) is arguably the most thoroughly cryptanalyzed of all unbroken traditional hashes (Keccak team); and so far, its security has not been affected by AI-assisted cryptanalysis.
Practical collision attacks have reached 5 of its 24 rounds; theoretical attacks against the underlying permutation used by Keccak-256, SHAKE128, and SHAKE256 reach 6 rounds (Guo et al. 2020, Zhang, Hou, and Liu 2024). It is built on the sponge construction: if the underlying permutation is ideal, the sponge construction is provably indistinguishable from a random oracle—holding for classical adversaries, and for quantum adversaries under a looser bound (Tokat, Alagic, Carolan, and Majenz, QCrypt 2026). This means the sponge construction is structurally sound, with no attacks exploiting the sponge itself. But there may be methods that directly attack the internal Keccak-f permutation.
Relative performance is precisely where Keccak-256 performs worse than other traditional hashes, especially in binary tree hashing scenarios. Nevertheless, leanVM proves Keccak-f at over 500,000 per second on EIP-7870 hardware, sufficient to meet the required aggregation throughput; it is just harder to prove than BLAKE3 and slower natively than SHA2-256. We accept this relative performance cost for the sake of security margin and historical cryptanalysis.
Keccak-256 vs. SHA3-256
Keccak-256 and SHA3-256 share the same Keccak-f permutation, the same rate and capacity, so their security, native speed, and proof cost are identical. The only difference is the padding bits. Essentially, every cryptanalytic result against one applies to the other, and every Keccak-f accelerator works for both functions.
The trade-off between the two comes down to integration issues within Ethereum:
- It is already in the protocol. KECCAK256 is already an opcode, widely used in the execution layer and application layer.
- It avoids two nearly identical functions. Having SHA3-256 coexist with Keccak-256 means two functions differing by only one padding byte. And both are easily called "SHA3" informally, since strictly speaking Keccak is a variant of the SHA3 family. Not introducing SHA3-256 avoids an entire class of integration bugs.
- FIPS certification does not help here. SHA3-256 is FIPS-certified, Keccak-256 is not, but choosing SHA3-256 does not make signatures FIPS-compliant, because the signature scheme itself is not within FIPS certification scope. For users who need FIPS compliance, we will satisfy this through another protocol-layer construction—one that allows users to verify arbitrary computation at low cost.
What This Means for Clients
For most teams, this choice requires almost no new code.
- EL clients: No new hash needed. Signature verification reuses the existing Keccak-256 implementation. In addition, when SSZ is introduced to the execution layer (which will likely happen in the context of frame transactions), we recommend using Keccak-256 alongside it.
- CL clients: Keccak-256 is already in use (discv5 node IDs use it). Long term, we recommend migrating SSZ's Merkleization from SHA2-256 to Keccak-256.
References
- Keccak team's cryptanalysis record
- Guo, Liao, Liu, Liu, Qiao, Song, Practical Collision Attacks against Reduced-Round SHA-3 (Journal of Cryptology, 2020)
- Zhang, Hou, Liu, Probabilistic Linearization: Internal Differential Collisions in up to 6 Rounds of SHA-3 (CRYPTO 2024, ePrint 2024/1136)
- Li, Liu, Wang, Shi, Pushing the Limit of Memory-Efficient Collision Attack Frameworks on SHA-2 (ePrint 2026/1080)
- Zhang, Li, Gao, Wang, Collision Attacks on up to 37-Step SHA-256 with Improved Trail Search (EUROCRYPT 2026, ePrint 2026/232)
- Tokat, Alagic, Carolan, Majenz: Quantum Indistinguishability of the Sponge Construction (QCrypt 2026)
- BLAKE2 Official Site: Cryptanalysis Q&A
- SNARK.fast: Flock Challenge Leaderboard (BLAKE3 Proof Throughput)
- EF Poseidon Cryptanalysis Initiative Announcement (IACR, December 2024)
- Sanso and Vitto, Attacking Poseidon with Graeffe-Based Root Finding (ePrint 2025/937)
- Bak et al., Claiming Bounties on Small-Scale Poseidon and Poseidon2 Instances (ePrint 2026/150)
- Bariant, Bouvier, Leurent, Perrin, Algebraic Attacks against Some Arithmetization-Oriented Primitives (ToSC 2022)
- Goldreich, A 38-Step Collision Attack on SHA-256 (ePrint 2026/2913)


