How can too much text take over a computer?
In 1988 a graduate student's experiment used a missing length check, among other tricks, and about two thousand computers were infected within fifteen hours.
▶ Start the storyToo much text can take over a computer when a program sets aside a fixed-size space for incoming data, never checks whether the data actually fits, and keeps writing past the end. This is a overflow. A buffer is just an area of set aside to hold data, and the memory next to it holds other things the program depends on, including its own variables and even instructions. When the extra data spills over, it overwrites its neighbours.
Picture pouring a large drink into a small cup on a crowded table. The overflow does not just make a mess; it lands on whatever sits next to the cup. If that happens to be your homework, you lose your homework. In a program, what sits next to the cup might be a note saying where to go next. A function remembers where to return when it finishes, and if the spill rewrites that note, the computer can end up following instructions chosen by someone else. That is how a long input can go from crashing a program to taking control of it.
The earliest documented hostile use came in 1988, when a Cornell graduate student named Robert Tappan Morris released a self-copying program, the Morris , onto the early Internet. One of its tricks used a overflow in a Unix service called finger. A friend said he wrote it simply to see if it could be done. Within fifteen hours about two thousand computers were infected, and Morris became the first person convicted of a felony under the Computer Fraud and Abuse Act.
2,000
The cure has two parts. Better programs check lengths and languages such as Java and Python do this for you. And operating systems add safety nets: shuffling where things sit in , planting guard values called , and marking data areas as not executable, so one slip is no longer enough.
Quiz me
0/3
Recap
Always check that data fits before writing it, and rely on languages and operating system safeguards for the cases people miss.
💡 A trick to remember it · A cup poured too full soaks the table: check the cup before you pour, and keep a tray (canaries, randomized layouts, no-execute memory) underneath.
Surprising fact · The 1988 Morris worm used a buffer overflow in the Unix finger service, and two thousand computers were infected within fifteen hours.
Sources (2)
No source, no claim. Every fact in this lesson (18 claims) cites at least one of these.