Recognise why accuracy is the wrong headline metric for DNS problems.
The demo that won the budget. A security vendor showed Tunde’s team a DNS classifier. It identified malicious domains with 99.7% accuracy on a held-out test set. Impressive! The team bought it.
The Monday that followed. In production, the system raised roughly 900 alerts a day. Of those, fewer than ten were genuinely malicious. Within three weeks, the team had muted the feed. The capability they had paid for was switched off, not by an attacker, but by themselves.
What went wrong? Nobody did the sums. Look at the arithmetic panel on the slide:
- Domains queried each day that are new to the network: 300,000.
- Genuinely malicious among them: about 30 (that is 0.01%).
- A “99.7% accurate” model is wrong 0.3% of the time. 0.3% of the roughly 299,970 harmless domains is about 900 false alarms.
So 900 false alarms drown out 30 real ones. The accuracy figure was true and, at the same time, irrelevant, because the thing being hunted is extremely rare. Imagine a smoke detector that rings 900 times a day. Within a week, someone takes out the battery.
This is called the base rate problem, and it is set out clearly in a well-known paper on machine learning for network intrusion detection (Sommer & Paxson, 2010). Intrusion detection is hostile terrain for machine learning because the events of interest are rare, false alarms cost real analyst time, and there is a big gap between “statistically unusual” and “worth acting on”. Notice also what the team did: they did not remove the tool, they muted it. That is worse, because the capability still appears on the architecture diagram while doing nothing.
When the thing you are hunting is rare, even a very low false-positive rate produces overwhelming noise. This is the best-documented reason machine learning fails in network security, and it applies to almost every DNS detection problem you will meet.
THINK ABOUT IT How many alerts a day can your team actually investigate? Write the number down. That number, not accuracy and not AUC, is the constraint every detection model must satisfy, and it should appear in the requirements before anyone trains anything.
