Fastest infection. Ever.
Bug identifier: MS02-039
Description: Buffer overruns in SQL Server 2000 Resolution Service could enable remote code execution
Alias: The SQL Slammer bug
Date published: July 24, 2002
While technically not an OS bug, the SQL Slammer bug deserves honorary mention due to the sheer velocity with which vulnerable systems were infected. The bug targeted Microsoft's database server. Vulnerable computers were subject to buffer overflows that, if properly crafted, could place commands into memory to cause the targeted system to execute those commands with the permissions of the database service.
Patching was complicated by the fact that admins needed to run an earlier patch before they could run the MS02-039 fix. The bug affected primarily corporate server systems, but also affected home users who had MSDE (Microsoft SQL Server Desktop Engine) installed. That made a number of home users, some of whom didn't even know they had MSDE on their machines, unwitting participants in the carnage to come.
Because the Slammer worm primarily targeted servers running databases, it didn't infect millions of machines. It did, however, spread rapidly -- so rapidly, in fact, that it had infected roughly 9 out of 10 vulnerable machines within 10 minutes of being released on January 25, 2003. The entire worm was only 376 bytes, and fit into a single packet of data.
The MS02-039 bug was "one of the biggest oversights of all time," says Steve Manzuik, senior manager of security research at Juniper Networks, "not because it was an easy or obvious bug to find -- it wasn't."
"At the time of the patch, no one realized that every vulnerable SQL installation was also listening on a UDP (User Datagram Protocol) port that they could be exploited over," Manzuik explains. "Many administrators simply locked down access to the SQL TCP ports while forgetting about UDP."
A postmortem by the Cooperative Association for Internet Data Analysis revealed that the worm was a model of efficiency, doubling the number of infected systems every 8.5 seconds, and flooding the Internet with so many infection attempts that routers shut down. When restarted, so many routers attempted to update their routing tables simultaneously that normal Internet traffic simply couldn't get through the gridlock.
Upshot: SQL Slammer demonstrated the power of a vulnerability that could fit within a single data packet, and brought home the lesson that a single application weakness could cause the entire Internet to grind to a standstill. And it's still out there, drifting around on a few old systems, looking for new hosts to infect.