API2Vec: Learning Representations of API Sequences for Malware Detection
Lei Cui, Jiancong Cui, Yuede Ji, Zhiyu Hao, Lun Li, Zhenquan Ding
Abstract
Analyzing malware based on API call sequence is an effective approach as the sequence reflects the dynamic execution behavior of malware. Recent advancements in deep learning have led to the application of these techniques for mining useful information from API call sequences. However, these methods mainly operate on raw sequences and may not effectively capture important information especially for multi-process malware, mainly due to the API call interleaving problem. Motivated by that, this paper presents API2Vec, a graph based API embedding method for malware detection. First, we build a graph model to represent the raw sequence. In particular, we design the temporal process graph (TPG) to model inter-process behavior and temporal API graph (TAG) to model intra-process behavior. With such graphs, we design a heuristic random walk algorithm to generate a number of paths that can capture the fine-grained malware behavior. By pre-training the paths using the Doc2Vec model, we are able to generate the embeddings of paths and APIs, which can further be used for malware detection. The experiments on a real malware dataset demonstrate that API2Vec outperforms the state-of-the-art embedding methods and detection methods for both accuracy and robustness, especially for multi-process malware. CCS CONCEPTS • Security and privacy → Malware and its mitigation; Software security engineering.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Cited by top-tier papers2
- MalwareTotal: Multi-Faceted and Sequence-Aware Bypass Tactics against Static Malware DetectionShuai He, Cai Fu, Hong Hu, Jiahe Chen et al.ICSE 2024 · 3 citations
- PowerPeeler: A Precise and General Dynamic Deobfuscation Method for PowerShell ScriptsRuijie Li, Chenyang Zhang, Huajun Chai, Lingyun Ying et al.CCS 2024 · 3 citations
Builds on6
- Asm2Vec: Boosting Static Representation Robustness for Binary Clone Search against Code Obfuscation and Compiler OptimizationSteven H. H. Ding, Benjamin C. M. Fung, Philippe CharlandS&P 2019 · 447 citations
- TESSERACT: Eliminating Experimental Bias in Malware Classification across Space and TimeFeargus Pendlebury, Fabio Pierazzi, Roberto Jordaney, Johannes Kinder et al.USENIX Security 2019 · 441 citations
- Transcend: Detecting Concept Drift in Malware Classification ModelsRoberto Jordaney, Kumar Sharad, Santanu Kumar Dash, Zhi Wang et al.USENIX Security 2017 · 325 citations
- Enhancing State-of-the-art Classifiers with API Semantics to Detect Evolved Android MalwareXiaohan Zhang, Yuan Zhang, Ming Zhong, Daizong Ding et al.CCS 2020 · 173 citations
- Dynamic Malware Analysis with Feature Engineering and Feature LearningZhaoqi Zhang, Panpan Qi, Wei WangAAAI 2020 · 153 citations
Related papers
- Log2vec: A Heterogeneous Graph Embedding Based Approach for Detecting Cyber Threats within EnterpriseFucheng Liu, Yu Wen, Dongxue Zhang, Xihe Jiang et al.CCS 2019 · 314 citations
- MalGraph: Hierarchical Graph Neural Networks for Robust Windows Malware DetectionXiang Ling, Lingfei Wu, Wei Deng, Zhenqing Qu et al.INFOCOM 2022 · 47 citations
- GAGE: Genetic Algorithm-Based Graph Explainer for Malware AnalysisMohd Saqib, Benjamin C. M. Fung, Philippe Charland, Andrew WalensteinICDE 2024 · 11 citations
- Careful About What App Promotion Ads Recommend! Detecting and Explaining Malware Promotion via App Promotion GraphShang Ma, Chaoran Chen, Shao Yang, Shifu Hou et al.NDSS 2025
- Enhancing Malware Detection for Android Apps: Detecting Fine-Granularity Malicious ComponentsZhijie Liu, Liang Feng Zhang, Yutian TangASE 2023 · 10 citations
