AsmRAG: LLM-Driven Malware Detection by Retrieving Functionally Similar Assembly Code
Not on the map. Why?
Abstract (arXiv)
Deep learning malware detectors achieve high classification accuracy but suffer from severe interpretability limitations, typically returning probabilistic verdicts that lack forensic context. We introduce AsmRAG, a framework performing malware analysis through Assembly-Level Retrieval-Augmented Generation. Unlike classifiers built on global statistical features, AsmRAG reformulates detection as an evidence-based retrieval task. The system uses a code-specialized Large Language Model (LLM) to analyze assembly functions and convert them into semantic embeddings. This process constructs a searchable knowledge base resilient to syntactic obfuscation. For inference, we propose a Density-Weighted Anchor Selection mechanism that isolates the primary unit of malicious logic within a binary to extract verifiable forensic evidence and resist evasion attempts. Testing on a curated dataset of 40k binaries shows AsmRAG reaching a detection F1-score of 96% alongside a family attribution F1-score of 95%. Comparisons confirm this semantic retrieval approach remains robust against metamorphic obfuscation. When holistic baselines (EMBER and ResNeXt) degrade, our methodology gives Security Operations Centers a transparent and reliable alternative.
Key facts. Cited by 1 paper in the map (data through 14 Oct 2026). First posted on arXiv 25 Apr 2026.
Builds on
No reference list yet.
Built on by
Citing papers per year: 2026: 1.
1 paper.
Similar, not cited
Close in wording, no citation either way
- 2025"Digital Camouflage": The LLVM Challenge in LLM-Based Malware Detection
- 2025XGen-Q: An Explainable Domain-Adaptive LLM Framework with Retrieval-Augmented Generation for Software Security
- 2026LCC-LLM: Leveraging Code-Centric Large Language Models for Malware Attribution
- 2026ALIBI: Adversarial Legitimacy Injection in Binary Input against LLM Malware Analyzers
- 2026Identifying Adversary Tactics and Techniques in Malware Binaries with an LLM Agent
- 2025Is "Knowing It's Malicious Enough?" Evaluating LLMs for Fine-Grained Malware Behavior Auditing
- 2026Trident: Improving Malware Detection with LLMs and Behavioral Features
- 2025Beyond Embeddings: Interpretable Feature Extraction for Binary Code Similarity