Apex › Security & web

Hash flooding & algorithmic-complexity DoS

How an attacker turns a hash table's O(1) into O(n²) with nothing but chosen keys. If the hash is predictable, thousands of distinct keys can be made to collide in one bucket — every insert walks a growing chain and one request pins a CPU (the 2011 hashDoS). Flood the buckets, then switch to a seeded SipHash-style hash and watch the same attack scatter harmlessly.

More in Security & web