Memory-Based Malware Detection: Leakage-and Temporal-Aware Evaluation
Abstract
Machine learning has become a standard approach for memory-based malware detection, yet evaluations on commonly used benchmarks can be inflated by randomized splits and artificially balanced datasets that ignore temporal evolution and real-world class distributions. In this work, we introduce a leakage-and temporal-aware evaluation framework for memory forensics by adapting the TESSERACT protocol to the CIC-MalMem-2022 benchmark. We identify and remove 12 environment-dependent features that encode sandbox artifacts rather than intrinsic malware behavior and reconstruct a family-level chronology to enforce causal train–test splits. Under this stricter protocol, reported performance drops substantially for some architectures (TabNet falls to 0.89 F1), whereas the hybrid meta-ensemble retains 0.987 F1, exposing biases that inflate standard results on the original benchmark. We then evaluate tree-based and deep learning architectures, including XGBoost, TabNet, and a semantically ordered 1D-CNN, and combine them into a hybrid meta-ensemble. While individual models exhibit varying sensitivity to concept drift, the ensemble achieves the most consistent performance across temporal splits under a 100:1 class imbalance. These results indicate that both evaluation design and model diversity are critical for developing robust memory-based malware detectors under realistic, non-stationary conditions.