Dos and Don'ts of Machine Learning in Computer Security
Not on the map. Why?
Abstract (arXiv)
With the growing processing power of computing systems and the increasing availability of massive datasets, machine learning algorithms have led to major breakthroughs in many different areas. This development has influenced computer security, spawning a series of work on learning-based security systems, such as for malware detection, vulnerability discovery, and binary code analysis. Despite great potential, machine learning in security is prone to subtle pitfalls that undermine its performance and render learning-based systems potentially unsuitable for security tasks and practical deployment. In this paper, we look at this problem with critical eyes. First, we identify common pitfalls in the design, implementation, and evaluation of learning-based security systems. We conduct a study of 30 papers from top-tier security conferences within the past 10 years, confirming that these pitfalls are widespread in the current security literature. In an empirical analysis, we further demonstrate how individual pitfalls can lead to unrealistic performance and interpretations, obstructing the understanding of the security problem at hand. As a remedy, we propose actionable recommendations to support researchers in avoiding or mitigating the pitfalls where possible. Furthermore, we identify open problems when applying machine learning in security and provide directions for further research.
Key facts. Cited by 98 papers in the map (data through 7 Oct 2026). First posted on arXiv 19 Oct 2020.
Builds on
No reference list yet.
Built on by
Citing papers per year: 2021: 1; 2022: 2; 2023: 14; 2024: 16; 2025: 25; 2026: 40.
98 papers.
Sort:
By area:
- 2021How to avoid machine learning pitfalls: a guide for academic researcherscited by 34
- 2023Uncovering the Limits of Machine Learning for Automatic Vulnerability Detectioncited by 30
- 2023Kairos: Practical Intrusion Detection and Investigation using Whole-system Provenancecited by 30
- 2025Frontier AI's Impact on the Cybersecurity Landscapecited by 21
- 2025From CVE Entries to Verifiable Exploits: An Automated Multi-Agent Framework for Reproducing CVEscited by 17
- 2023Illuminati: Towards Explaining Graph Neural Networks for Cybersecurity Analysiscited by 14
- 2023Decoding the Secrets of Machine Learning in Malware Classification: A Deep Dive into Datasets, Feature Extraction, and Model Performancecited by 12
- 2023Efficient Query-Based Attack against ML-Based Android Malware Detection under Zero Knowledge Settingcited by 10
- 2024TESSERACT: Eliminating Experimental Bias in Malware Classification across Space and Time (Extended Version)cited by 9
- 2023LogPr'ecis: Unleashing Language Models for Automated Malicious Log Analysiscited by 8
- 2024Adversarial Robustness of AI-Generated Image Detectors in the Real Worldcited by 6
- 2025When AI Meets the Web: Prompt Injection Risks in Third-Party AI Chatbot Pluginscited by 6
38 more
- 2024Assessing the Impact of Packing on Machine Learning-Based Malware Detection and Classification Systemscited by 5
- 2025Trace Gadgets: Minimizing Code Context for Machine Learning-Based Vulnerability Predictioncited by 5
- 2022Fantomas: Understanding Face Anonymization Reversibilitycited by 4
- 2024Enhancing Source Code Security with LLMs: Demystifying The Challenges and Generating Reliable Repairscited by 4
- 2024LLM Detectors Still Fall Short of Real World: Case of LLM-Generated Short News-Like Postscited by 4
- 2025A Crack in the Bark: Leveraging Public Knowledge to Remove Tree-Ring Watermarkscited by 4
- 2026Adversarial News and Lost Profits: Manipulating Headlines in LLM-Driven Algorithmic Tradingcited by 4
- 2026SoK: The Pitfalls of Deep Reinforcement Learning for Cybersecuritycited by 4
- 2024Bi-Directional Transformers vs. word2vec: Discovering Vulnerabilities in Lifted Compiled Codecited by 2
- 2025Defending against Adversarial Malware Attacks on ML-based Android Malware Detection Systemscited by 2
- 2025Neuro-Symbolic AI for Cybersecurity: State of the Art, Challenges, and Opportunitiescited by 2
- 2025Demystifying Network Foundation Modelscited by 2
- 2023Reassessing feature-based Android malware detection in a contemporary contextcited by 1
- 2023Group-based Robustness: A General Framework for Customized Robustness in the Real Worldcited by 1
- 2023Testing the Consistency of Performance Scores Reported for Binary Classification Problemscited by 1
- 2023Light up that Droid! On the Effectiveness of Static Analysis Features against App Obfuscation for Android Malware Detectioncited by 1
- 2023IoTGeM: Generalizable Models for Behaviour-Based IoT Attack Detectioncited by 1
- 2024A Training Rate and Survival Heuristic for Inference and Robustness Evaluation (TRASHFIRE)cited by 1
- 2024Single-GPU GNN Systems: Traps and Pitfallscited by 1
- 2024SISSA: Real-time Monitoring of Hardware Functional Safety and Cybersecurity with In-vehicle SOME/IP Ethernet Trafficcited by 1
- 2024R+R: Revisiting Static Feature-Based Android Malware Detection using Machine Learningcited by 1
- 2024A Novel Perturb-ability Score to Mitigate Evasion Adversarial Attacks on Flow-Based ML-NIDScited by 1
- 2024Comparing Unidirectional, Bidirectional, and Word2vec Models for Discovering Vulnerabilities in Compiled Lifted Codecited by 1
- 2025Designing a reliable lateral movement detector using a graph foundation modelcited by 1
- 2025Empirical Quantification of Spurious Correlations in Malware Detectioncited by 1
- 2025VOLTRON: Detecting Unknown Malware Using Graph-Based Zero-Shot Learningcited by 1
- 2025Demystifying the Role of Rule-based Detection in AI Systems for Windows Malware Detectioncited by 1
- 2025HiGraph: A Large-Scale Hierarchical Graph Dataset for Malware Analysiscited by 1
- 2026Supporting Artifact Evaluation with LLMs: A Study with Published Security Research Paperscited by 1
- 2026Towards Reliable Local Security Agents: Verifiable Post-Training for Linux Privilege Escalationcited by 1
- 2026CASCADE: A Component Ablation and Corpus Audit of a Layered Local Defense for MCP-Based Systemscited by 1
- 2026SoK: Where Do Flow Labels Come From? Auditing Label Provenance in Encrypted Traffic Benchmarkscited by 1
- 2026SENTINEL-RL: Offloading Topological Reasoning from LLM Agents in the Security Operations Centercited by 1
- 2022SimCLF: A Simple Contrastive Learning Framework for Function-level Binary Embeddingscited by 0
- 2023Effectiveness of Moving Target Defenses for Adversarial Attacks in ML-based Malware Detectioncited by 0
- 2023Towards machine learning guided by best practicescited by 0
- 2023Is there a Trojan! : Literature survey and critical evaluation of the latest ML based modern intrusion detection systems in IoT environmentscited by 0
- 2024Improving Adversarial Robustness in Android Malware Detection by Reducing the Impact of Spurious Correlationscited by 0
50 most cited of 98 All 98 (JSON)
- 2026Physics-Attested Federated Learning: Securing Collaborative Anomaly Detection in Critical Water Infrastructure28 Sep 2026
- 2026HESP: Separating What to Probe from When to Stop in Local LLM Alert-Triage Agents27 Sep 2026
- 2026AnchorMixGAN: Anchor-Aligned Generative Semi-Supervision for DDoS Detection in Cloud-Integrated IoT Networks26 Sep 2026
- 2026Unmasking Shortcut Learning in IoT Intrusion Detection: A Forensic, Multi-Paradigm Evaluation of Feature Dependence and Data Leakage23 Sep 2026
- 2026BRFID: Toward Byzantine-Robust Federated Intrusion Detection23 Sep 2026
- 2026Multi-View Fusion for Encrypted C2 Detection: A Leakage-Controlled Measurement Study of Evaluation Pitfalls23 Sep 2026
- 2026Temporal Generalization and Explanation Stability of Control Flow Graph Neural Networks for Malware Detection21 Sep 2026
- 2026Delphi Scanner: efficient and interpretable static malware detection via API sequence modeling17 Sep 2026
- 2026A Cyber Range Evaluation of Autonomous Network Incident Response Agents15 Sep 2026
- 2026A Three-Axis Stress Test of LLM vs Classical ML for Network Intrusion Detection under Distribution Shift and Adversarial Evasion11 Sep 2026
- 2026Forging Tree-Ring: Reproducing and Instrumenting Black-Box Semantic Watermark Forgery11 Sep 2026
- 2026Cost-Aware Hierarchical Multi-Agent Ransomware Detection and Family Attribution4 Sep 2026
38 more
- 2026Candidate Comparability Before Promotion: Conditional Validation in Adaptive Network Intrusion Detection3 Sep 2026
- 2026SENTINEL-RL: Offloading Topological Reasoning from LLM Agents in the Security Operations Center3 Sep 2026
- 2026Population-Calibrated Graph Screening at 835-Million-Address Scale, with Label-Free Transfer to New Chains2 Sep 2026
- 2026SoK: Where Do Flow Labels Come From? Auditing Label Provenance in Encrypted Traffic Benchmarks2 Sep 2026
- 2026Ranked by the Matcher: A Reproducibility Audit of Knowledge Graph Extraction from Threat Reports1 Sep 2026
- 2026REPLICANT: Learning Policies for Evading and Hardening Malware Detectors28 Aug 2026
- 2026Provenance, Not Behaviour: A Serialisation Artifact in Edge-IIoTset and a Leakage-Free Benchmark for Precision-Agriculture Intrusion Detection16 Aug 2026
- 2026Benchmarking Quantum Machine Learning for Power-System Attack Detection: Evaluation Choices Decide the Outcome Before the Models Do16 Aug 2026
- 2026How Benchmarks and Evaluation Protocols Shape Conclusions in Provenance-Based Intrusion Detection2 Aug 2026
- 2026SemiScope: Disentangling Classifier Tuning and Joint Optimization in Semi-Supervised Security Classification30 Jun 2026
- 2026SoK: AI-Augmented Binary Reversing16 Jun 2026
- 2026SEED: Semi-supervised Continual MalwarE Detection for Tackling ConcEpt Drift on a BuDget24 May 2026
- 2026Stream Assembly Is an Uncontrolled Treatment in Streaming Intrusion-Detection Benchmarks23 May 2026
- 2026Security Document Classification with a Fine-Tuned Local Large Language Model: Benchmark Data and an Open-Source System19 May 2026
- 2026A No-Defense Defense Against Gradient-Based Adversarial Attacks on ML-NIDS: Is Less More?18 May 2026
- 2026A Comprehensive Evaluation of Code Language Models for Security Patch Detection13 May 2026
- 2026Quantifiable Uncertainty: A Stochastic Consensus Multi-Agent RAG Framework for Robust Malware Detection8 May 2026
- 2026CASCADE: A Component Ablation and Corpus Audit of a Layered Local Defense for MCP-Based Systems18 Apr 2026
- 2026Verify Before You Fix: Agentic Execution Grounding for Trustworthy Cross-Language Code Analysis12 Apr 2026
- 2026Can LLMs Infer Conversational Agent Users' Personality Traits from Chat History?31 Mar 2026
- 2026Improving Generalization on Cybersecurity Tasks with Multi-Modal Contrastive Learning20 Mar 2026
- 2026Towards Reliable Local Security Agents: Verifiable Post-Training for Linux Privilege Escalation18 Mar 2026
- 2026Spatio-Temporal Attention Graph Neural Network: Explaining Causalities With Attention11 Mar 2026
- 2026Supporting Artifact Evaluation with LLMs: A Study with Published Security Research Papers6 Mar 2026
- 2026Detecting Cybersecurity Threats by Integrating Explainable AI with SHAP Interpretability and Strategic Data Sampling22 Feb 2026
- 2026SoK: The Pitfalls of Deep Reinforcement Learning for Cybersecurity9 Feb 2026
- 2026From Data Leak to Secret Misses: The Impact of Data Leakage on Secret Detection Models30 Jan 2026
- 2026Adversarial News and Lost Profits: Manipulating Headlines in LLM-Driven Algorithmic Trading19 Jan 2026
- 2025From Lab to Reality: A Practical Evaluation of Deep Learning Models and LLMs for Vulnerability Detection11 Dec 2025
- 2025One Detector Fits All: Robust and Adaptive Detection of Malicious Packages from PyPI to Enterprises3 Dec 2025
- 2025PaTAS: A Framework for Trust Propagation in Neural Networks Using Subjective Logic25 Nov 2025
- 2025SoK: Security Evaluation of Wi-Fi CSI Biometrics: Attacks, Metrics, and Open Challenges14 Nov 2025
- 2025When AI Meets the Web: Prompt Injection Risks in Third-Party AI Chatbot Plugins8 Nov 2025
- 2025Evaluating Line-level Localization Ability of Learning-based Code Vulnerability Detection Models13 Oct 2025
- 2025Demystifying Network Foundation Models27 Sep 2025
- 2025A Global Analysis of Cyber Threats to the Energy Sector: "Currents of Conflict" from a Geopolitical Perspective26 Sep 2025
- 2025BEACON: Behavioral Malware Classification with Large Language Model Embeddings and Deep Learning18 Sep 2025
- 2025Neuro-Symbolic AI for Cybersecurity: State of the Art, Challenges, and Opportunities8 Sep 2025
50 newest of 98 All 98 (JSON)
- 2025From CVE Entries to Verifiable Exploits: An Automated Multi-Agent Framework for Reproducing CVEscited by 17
- 2026Towards Reliable Local Security Agents: Verifiable Post-Training for Linux Privilege Escalationcited by 1
- 2026CASCADE: A Component Ablation and Corpus Audit of a Layered Local Defense for MCP-Based Systemscited by 1
- 2026Verify Before You Fix: Agentic Execution Grounding for Trustworthy Cross-Language Code Analysiscited by 0
- 2026Can LLMs Infer Conversational Agent Users' Personality Traits from Chat History?cited by 0
- 2026Cost-Aware Hierarchical Multi-Agent Ransomware Detection and Family Attributioncited by 0
- 2026HESP: Separating What to Probe from When to Stop in Local LLM Alert-Triage Agentscited by 0
- 2026HESP: Separating What to Probe from When to Stop in Local LLM Alert-Triage Agents27 Sep 2026
- 2026Cost-Aware Hierarchical Multi-Agent Ransomware Detection and Family Attribution4 Sep 2026
- 2026CASCADE: A Component Ablation and Corpus Audit of a Layered Local Defense for MCP-Based Systems18 Apr 2026
- 2026Verify Before You Fix: Agentic Execution Grounding for Trustworthy Cross-Language Code Analysis12 Apr 2026
- 2026Can LLMs Infer Conversational Agent Users' Personality Traits from Chat History?31 Mar 2026
- 2026Towards Reliable Local Security Agents: Verifiable Post-Training for Linux Privilege Escalation18 Mar 2026
- 2025From CVE Entries to Verifiable Exploits: An Automated Multi-Agent Framework for Reproducing CVEs1 Sep 2025
- 2021How to avoid machine learning pitfalls: a guide for academic researcherscited by 34
- 2023Uncovering the Limits of Machine Learning for Automatic Vulnerability Detectioncited by 30
- 2023Kairos: Practical Intrusion Detection and Investigation using Whole-system Provenancecited by 30
- 2025Frontier AI's Impact on the Cybersecurity Landscapecited by 21
- 2023Illuminati: Towards Explaining Graph Neural Networks for Cybersecurity Analysiscited by 14
- 2023Decoding the Secrets of Machine Learning in Malware Classification: A Deep Dive into Datasets, Feature Extraction, and Model Performancecited by 12
- 2023Efficient Query-Based Attack against ML-Based Android Malware Detection under Zero Knowledge Settingcited by 10
- 2024TESSERACT: Eliminating Experimental Bias in Malware Classification across Space and Time (Extended Version)cited by 9
- 2023LogPr'ecis: Unleashing Language Models for Automated Malicious Log Analysiscited by 8
- 2024Adversarial Robustness of AI-Generated Image Detectors in the Real Worldcited by 6
- 2024Assessing the Impact of Packing on Machine Learning-Based Malware Detection and Classification Systemscited by 5
- 2025Trace Gadgets: Minimizing Code Context for Machine Learning-Based Vulnerability Predictioncited by 5
12 most cited of 86 All 86 (JSON)
- 2026Physics-Attested Federated Learning: Securing Collaborative Anomaly Detection in Critical Water Infrastructure28 Sep 2026
- 2026AnchorMixGAN: Anchor-Aligned Generative Semi-Supervision for DDoS Detection in Cloud-Integrated IoT Networks26 Sep 2026
- 2026Unmasking Shortcut Learning in IoT Intrusion Detection: A Forensic, Multi-Paradigm Evaluation of Feature Dependence and Data Leakage23 Sep 2026
- 2026BRFID: Toward Byzantine-Robust Federated Intrusion Detection23 Sep 2026
- 2026Multi-View Fusion for Encrypted C2 Detection: A Leakage-Controlled Measurement Study of Evaluation Pitfalls23 Sep 2026
- 2026Temporal Generalization and Explanation Stability of Control Flow Graph Neural Networks for Malware Detection21 Sep 2026
- 2026Delphi Scanner: efficient and interpretable static malware detection via API sequence modeling17 Sep 2026
- 2026A Cyber Range Evaluation of Autonomous Network Incident Response Agents15 Sep 2026
- 2026A Three-Axis Stress Test of LLM vs Classical ML for Network Intrusion Detection under Distribution Shift and Adversarial Evasion11 Sep 2026
- 2026Candidate Comparability Before Promotion: Conditional Validation in Adaptive Network Intrusion Detection3 Sep 2026
- 2026Population-Calibrated Graph Screening at 835-Million-Address Scale, with Label-Free Transfer to New Chains2 Sep 2026
- 2026SoK: Where Do Flow Labels Come From? Auditing Label Provenance in Encrypted Traffic Benchmarks2 Sep 2026
12 newest of 86 All 86 (JSON)