Adversarial Robustness Analysis of Malware Classification Models Using FGSM and Defensive Techniques
This paper presents a complete framework for evaluating the adversarial robustness of machine-learning-based malware classifiers using static Windows Portable Executable (PE) features. The system integrates feature engineering, neural classification, adversarial attack generation, and defensive countermeasures into a single reproducible workflow. The dataset consists of PE header metadata, DLL imports, API function usage, and section-level information collected from the Windows Malwares dataset on Kaggle. After merging and preprocessing these sources, a Random Forest model is used for feature importance ranking, and the top 100 most relevant features are selected for training. A custom neural network model, MalwareNet, built in PyTorch, serves as the primary classifier. Adversarial examples are generated using the Fast Gradient Sign Method (FGSM) to simulate evasion attacks commonly used against ML-based malware detectors. Two defense mechanisms are implemented and evaluated: Adversarial Training — improves robustness by training the model on FGSM-perturbed samples. Feature Squeezing — reduces input precision to remove fine-grained adversarial noise. Extensive experiments demonstrate that adversarial attacks can significantly degrade malware detection accuracy (from 83% to 48%), while adversarial training improves robust accuracy to 79%. Feature squeezing provides lightweight but limited protection. This project includes the complete implementation code, experiments, visualizations, and analysis necessary to replicate and extend the study. It serves as a practical resource for research in adversarial machine learning, malware detection, and cybersecurity-focused ML robustness.
Institutions
- Institute of Engineering (NP)
Publication Details
- Journal
- Zenodo (CERN European Organization for Nuclear Research)
- Published
- 2025-12-05
- DOI
- https://doi.org/10.5281/zenodo.17832262
- Primary Topic
- Adversarial Robustness in Machine Learning
- Type
- article
- Field-Weighted Citation Impact
- 0.00