← Lab /AI/ML

ViPER detects malware with 85% balanced accuracy even on packed binaries

ViPER achieves balanced accuracy of 0.8521 and high packing detection AUC on a large PE image dataset

AI/ML arXiv 11 Jun 2026 Method Prototype evidence

Published as “ViPER: Vision-based Packing-Aware Encoder for Robust Malware Detection”

Why it matters

Higher true-positive rates at very low false-positive budgets can improve practical malware screening where false alarms are costly.

Summary

ViPER achieves a ROC-AUC of 0.9260 and AUPR of 0.9279 on a 30,000-sample test set, outperforming CNN baselines by up to 0.0256 AUC and delivering a higher true-positive rate at 1% false-positive budget. The improvement comes from a dual-head vision transformer that jointly learns malware and packing detection, with a residual gating layer that modulates the malware logits using packing confidence. Evidence is based on held-out evaluation, ablation studies, and comparisons to strong baselines, though the gain from the packing-aware components alone is modest.

What they found 3

  1. ViPER attains 0.9260 ROC-AUC on malware detection.

    “ViPER (proposed) 0.8521 0.9260 0.9279”

  2. The auxiliary packing detection head reaches 0.9949 AUC.

    “ViPER pack head 0.9688 0.9949 -”

  3. ViPER improves over ResNet-50 by +0.0239 AUC, +0.0185 AUPR, and +0.0434 TPR@1%FPR.

    “Δ vs. ResNet-50 +0.0239 +0.0185 +0.0434”

Caveats 6

  • The residual gate adds only +0.0017 AUC over the dual-head model without gating, indicating a very small incremental benefit.
  • Balanced accuracy remains unchanged (0.8521) when adding the gate, suggesting the gating mainly affects ranking quality rather than threshold-dependent accuracy.
  • ViPER currently frames malware detection as a binary classification problem.
  • identifying the specific packer or protector type rather than a binary packed/unpacked label could further refine the gating signal
  • exploring adaptive row-width representations that preserve section boundaries could enrich the visual features available to the backbone beyond the single fixed row width used in the current implementation.
  • packing prevalence is substantial in both classes (76.20% malware, 73.08% benign), indicating that packing state alone is an insufficient discriminator

What’s new here 4

  • Introduces a dual-head transformer where packing detection is an auxiliary supervised task integrated with malware classification.
  • Adds a learnable residual gating layer that fuses packing confidence into the malware head logits.
  • Applies parameter-efficient LoRA fine-tuning to a self-supervised ViT-B/14 backbone for byteplot images.
  • Demonstrates the approach on a large real-world dataset where packing is prevalent in both malicious and benign binaries.