The “buffer overflow” is amongst the top five cybersecurity vulnerabilities. 1
The first self-propagating Internet worm—1988’s Morris Worm—used a buffer overflow in the Unix finger daemon to spread from machine to machine.2 Today, almost thirty years later, we still haven’t learned our lessons.
At its core, the buffer overflow is an astonishingly simple bug that results from bad programming practices which are (embarrassingly) common.
What is a buffer, and how does it overflow?
Computer programs frequently operate on chunks of data that are read from a file, from the network, or even from the keyboard. Programs allocate finite-sized blocks of memory—buffers—to store this data as they work on it. A buffer overflow occurs when more data is written to, or read from, a buffer than the buffer can hold.
How is this exploited?
An attacker attempting to abuse a buffer overflow can push oversized data into the buffer, get his or her malicious unsigned code to execute, and can wreck havoc.
On the face of it, a buffer overflow sounds like a foolish error a novice programmer would make. One would be right to assume that the programmer writing the code knows how big the buffer is, and that it should be simple to make sure that the program never tries to cram more into the buffer than it knows will fit. Yet buffer overflows continue to happen, professional programmers continue to err, and the results are frequently a “security catastrophe”.2
Not too long ago, the Linux NetUSB drivers (commonly present in Netgear, D-Link, and TP-Link devices) were found to have a “simple” buffer overflow flaw which potentially put “millions of routers” at risk. 3
- Paganini, P. (2016, February 23). The Top Five Cyber Security Vulnerabilities. Retrieved from http://resources.infosecinstitute.com/the-top-five-cyber-security-vulnerabilities-in-terms-of-potential-for-catastrophic-damage/
- Bright, P. (2015, August 25). How security flaws work: The buffer overflow. Retrieved from https://arstechnica.com/security/2015/08/how-security-flaws-work-the-buffer-overflow/
- Bright, P. (2015, May 20). ’90s-style security flaw puts “millions” of routers at risk. Retrieved from https://arstechnica.com/security/2015/05/90s-style-security-flaw-puts-millions-of-routers-at-risk/