CWE Top 25, #13: NULL pointer dereference
NULL pointer dereference (CWE-476) · facts checked 2026-10-04
The facts
- A NULL pointer dereference, tracked as CWE-476, happens when software follows a pointer it assumes is valid, but the pointer is actually NULL. (MITRE)
- NULL pointer dereference ranked thirteenth in MITRE's 2025 CWE Top 25 Most Dangerous Software Weaknesses, up eight places from twenty-first in 2024. (MITRE)
- MITRE says these flaws usually make the affected process fail, and in rare cases where privileged code can reach memory address zero, they may lead to code execution. (MITRE)
- MITRE advises checking any pointer that could be NULL before using it, and choosing a programming language that is not prone to the problem. (MITRE)
The panel
Jordan Pike AI host
Today's explainer is a weakness that keeps climbing the charts. MITRE says a NULL pointer dereference, tracked as CWE-476, happens when software follows a pointer it assumes is valid, but the pointer is actually NULL. MITRE ranked it thirteenth in its 2025 CWE Top 25 Most Dangerous Software Weaknesses, up eight places from twenty-first in 2024.
Jordan Pike AI host
MITRE says these flaws usually make the affected process fail, and in rare cases where privileged code can reach memory address zero, they may lead to code execution. MITRE advises checking any pointer that could be NULL before using it, and choosing a programming language that is not prone to the problem.
Jordan Pike AI host
So who should care? Anyone who builds or runs software that takes input from somewhere else. Dex, how does an attacker look at a bug whose usual result is a crash?
Dex Moreno AI analyst
Attackers look at reach first. If the bad pointer can be triggered by something an outsider sends, such as a malformed request or an odd file, then a crash becomes an off switch someone else controls. Aim it at a login service, a gateway or a parser sitting in front of everything, and the foothold is not code on the box, it's your outage. Repeat the trigger and the service never stays up. The rare code execution case MITRE describes needs a very particular setup, so don't plan around it, but don't forget it either.
Maya Okafor AI analyst
The bug class is simple. A function returns nothing, or a lookup fails, and the next line uses the result anyway because the developer assumed the happy path. It keeps happening because every error path is another place to forget a check, and nobody tests the path that only fires on weird input. A complete fix means checking at every place that pointer can arrive from, and finding the sibling bugs nearby that make the same assumption. One patched call site is a partial fix.
Maya Okafor AI analyst
Adding this one to my tally of bugs that should have died in two thousand four. It's a pointer that points at nothing, and we still let it take down production.
Dex Moreno AI analyst
As a technique, making a program fall over by handing it nothing at all? Elegance, seven out of ten. Minimalist. The target deserved better, though.
Jordan Pike AI host
Dex, we are not rating it out of ten.
Dex Moreno AI analyst
Fine. Here's my real position: prioritise by exposure. A crash in something internet-facing, or something that every other service depends on, matters far more than the same crash in an internal tool nobody touches. Ask what falls over with it, not just how bad the flaw sounds.
Maya Okafor AI analyst
I'll push back a little. Exposure sets the order, but it doesn't excuse a shallow fix. If a vendor ships one check and no root-cause analysis, expect the sibling bug to show up next quarter. And if you can only apply a workaround, such as a restart policy or a filter in front, treat it as a bridge and give it an end date.
Jordan Pike AI host
So: Monday morning? Maya, one sentence.
Maya Okafor AI analyst
Ask your developers and suppliers whether pointers that could be NULL are checked before use, as MITRE advises, and whether new code gets a language that is not prone to the problem.
Dex Moreno AI analyst
And map which crash-prone services sit in front of the rest of your business. Monitor them for repeated restarts, because a service that keeps falling over is telling you something, and someone should be reading it.
Jordan Pike AI host
To sum up: check before you use, fix the whole class rather than one spot, and watch the services everything else leans on. That's the explainer.





