SipHash
A fast keyed hash function designed so that, without the secret key, attackers cannot predict or engineer collisions.
In more detail
Randomising a simple hash hides its outputs only as long as they are not observed; SipHash stays unpredictable even when outputs leak, as long as the key does not. CPython has used SipHash for str and bytes hashing since version 3.4. It is not a replacement for SHA-256 in integrity checks.
Related terms
- hash randomisation — Mixing a secret random value, chosen when a process starts, into string hashing so that hash values cannot be predicted from outside.
- hash flooding — An attack that sends a server many keys crafted to collide in its hash tables, turning each O(1) operation into O(n) and exhausting its CPU.
Taught in
- Collisions In Practice And Hash Flooding — Algorithms & Data Structures for Working Engineers