Skip to main content
QUICK REVIEW

[Paper Review] NtMalDetect: A Machine Learning Approach to Malware Detection Using Native API System Calls

Chan Woo Kim|arXiv (Cornell University)|Feb 15, 2018
Advanced Malware Detection TechniquesComputer Science4 references31 citations
TL;DR

This paper proposes NtMalDetect, a dynamic malware detection system that treats system call traces as text documents and applies natural language processing techniques—specifically TF-IDF weighted n-grams and linear SVMs—for binary classification of benign vs. malicious programs. It achieves 96% accuracy and 95% recall using system call sequences, with SVMs optimized via stochastic gradient descent proving most effective and efficient.

ABSTRACT

As computing systems become increasingly advanced and as users increasingly engage themselves in technology, security has never been a greater concern. In malware detection, static analysis, the method of analyzing potentially malicious files, has been the prominent approach. This approach, however, quickly falls short as malicious programs become more advanced and adopt the capabilities of obfuscating its binaries to execute the same malicious functions, making static analysis extremely difficult for newer variants. The approach assessed in this paper is a novel dynamic malware analysis method, which may generalize better than static analysis to newer variants. Inspired by recent successes in Natural Language Processing (NLP), widely used document classification techniques were assessed in detecting malware by doing such analysis on system calls, which contain useful information about the operation of a program as requests that the program makes of the kernel. Features considered are extracted from system call traces of benign and malicious programs, and the task to classify these traces is treated as a binary document classification task of system call traces. The system call traces were processed to remove the parameters to only leave the system call function names. The features were grouped into various n-grams and weighted with Term Frequency-Inverse Document Frequency. This paper shows that Linear Support Vector Machines (SVM) optimized by Stochastic Gradient Descent and the traditional Coordinate Descent on the Wolfe Dual form of the SVM are effective in this approach, achieving a highest of 96% accuracy with 95% recall score. Additional contributions include the identification of significant system call sequences that could be avenues for further research.

Motivation & Objective

  • To address the limitations of static malware analysis in detecting obfuscated or zero-day malware variants.
  • To evaluate the effectiveness of document classification techniques from NLP in analyzing system call traces for malware detection.
  • To identify the most informative system call sequences that distinguish malicious from benign behavior.
  • To develop a deployable, open-source system (NtMalDetect) integrating trained classifiers for real-world use.

Proposed method

  • System call traces from benign and malicious programs are extracted and stripped of parameters, retaining only function names.
  • Features are generated as n-grams (1- to 10-grams) of system call sequences, with TF-IDF weighting to emphasize rare but discriminative sequences.
  • Binary classification is performed using various machine learning models, including linear SVMs (optimized via SGD and coordinate descent), k-NN, and Naive Bayes.
  • The most informative features are extracted from the SVM classifier using L1 and L2 regularization to identify critical system call patterns.
  • A boosted ensemble of classifiers is used in the final NtMalDetect system to improve detection robustness.
  • The system is implemented using Scikit-learn and released as open source on GitHub.

Experimental results

Research questions

  • RQ1Can system call traces be effectively modeled as text documents for malware classification using NLP techniques?
  • RQ2Which machine learning algorithms perform best in classifying system call traces as benign or malicious?
  • RQ3Which system call n-gram sequences are most discriminative for identifying malicious behavior?
  • RQ4How do different regularization and optimization strategies affect the performance and efficiency of the classifier?

Key findings

  • Linear SVMs optimized via stochastic gradient descent achieved the highest accuracy of 96% and recall of 95% on the test set.
  • The L2 penalty SVM with SGD optimization was the fastest in both training and inference, with testing time under 0.001 seconds.
  • The most informative features identified by the L1-regularized SVM included repeated calls to NtQueryInformationThread and NtMapViewOfSection, suggesting behavioral patterns linked to malware.
  • The L2-regularized SVM highlighted sequences involving NtDelayExecution and NtDeviceIoControlFile, indicating potential indicators of malicious behavior.
  • The system demonstrated strong generalization to unseen malware variants, outperforming traditional static analysis in detecting obfuscated or zero-day threats.
  • The open-source NtMalDetect framework successfully integrates the trained models into a deployable tool for real-time malware detection.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.