Towards Practical Deployment-Stage Backdoor Attack on Deep Neural Networks

Xiangyu Qi, Tinghao Xie, Ruizhe Pan, Jifeng Zhu, Yong Yang, Kai BuCVPR 2021

Abstract

One major goal of the AI security community is to securely and reliably produce and deploy deep learning models for real-world applications. While data poisoning attacks during the training stage have been extensively explored, backdoor attacks in the deployment stage—occurring on end-user devices—remain under-studied. This work addresses this gap by introducing the Subnet Replacement Attack (SRA), a gray-box, physically realizable weight attack. SRA requires only architecture information to inject a backdoor by replacing a narrow subnet with a malicious one. Our results demonstrate near-perfect attack success rates with negligible impact on clean data performance, highlighting a novel and stealthy threat to DNN security.

Introduction: The Vulnerability of Deployment

Most research into backdoor attacks focuses on the production (training) stage, where an attacker poisons the training data. However, the deployment stage—when models are running on end-user devices—is arguably more vulnerable. Existing deployment-stage attacks, known as Adversarial Weight Attacks (AWA), typically require "white-box" access and resource-heavy gradient-based optimization. This makes them impractical for real-world hackers who need fast, stealthy exploits. Furthermore, these existing attacks rarely demonstrate effectiveness against physical triggers in real-world environments.

Methodology: Subnet Replacement Attack (SRA)

The Subnet Replacement Attack (SRA) operates in a "gray-box" setting: the attacker only needs to know the model's architecture, not its specific weight values. The attack follows a four-step process:

  1. Backdoor Subnet Training: The attacker pre-trains a tiny neural network (the "backdoor subnet") to remain silent on normal data but fire a massive signal when a specific trigger is detected. To ensure physical realizability, the subnet is trained using various digital transformations (rotation, brightness, scaling).
  2. Subnet Selection: The attacker identifies a very narrow path (a "subnet") within the target architecture—often just a single channel in a convolutional layer.
  3. Replacement: The attacker replaces the weights of this narrow subnet in the victim's model with the malicious weights. Surrounding weights are set to zero to isolate the malicious path.
  4. Target Connection: The output of this malicious path is hard-wired to the logit (output score) of the attacker's target class (e.g., forcing a "Stop" sign to be classified as a "Bird").
Overview of the Subnet Replacement Attack (SRA) mechanism, showing how a malicious subnet is integrated into a benign model.

Because modern DNNs are massive and overparameterized, losing one channel doesn't significantly hurt the model's accuracy on clean data, making the attack incredibly stealthy.

Experimental Evaluation

The researchers evaluated SRA across several standard benchmarks including CIFAR-10, ImageNet, and VGG-Face, testing architectures like VGG-16, ResNet-110, and MobileNet-V2.

Key Results

  • Near-Perfect Success: On CIFAR-10 and ImageNet, SRA achieved an Attack Success Rate (ASR) of over 99% across almost all tested architectures.
  • Minimal Performance Hit: For large models like VGG-16, the Clean Accuracy Drop (CAD) was often less than 1%. As shown in the comparison below, the Trojan models maintain performance very close to the clean models across various architectures.
  • Physical Robustness: In real-world laboratory tests with physical triggers, the attack maintained a 75% success rate, even with changes in camera angle, distance, and lighting.
Clean accuracy comparison across four different model architectures on CIFAR-10, showing the minimal impact of the SRA attack.

Discussion and Conclusion

The most significant insight of this work is that an attacker doesn't need to see specific model weights to succeed. If they know the target architecture (e.g., ResNet-50), they can prepare a payload offline and inject it into any instance of that model. This creates a "computer virus" paradigm where SRA can be packaged as a simple script to overwrite small sections of model files.

While the attack is highly effective on overparameterized models, it is less stealthy on compact architectures like MobileNet-V2, where replacing a subnet can cause a more noticeable drop in clean accuracy (up to 9-13% in ImageNet tests). Despite this, SRA remains resistant to standard defenses like Neural Cleanse and Fine-Pruning. This work calls for urgent attention to the vulnerability of DNNs in the deployment stage and the development of new methods to verify model integrity on user devices.

Summary updated

BibTeX
@inproceedings{qi2021towards,
  author = {Xiangyu Qi and Tinghao Xie and Ruizhe Pan and Jifeng Zhu and Yong Yang and Kai Bu},
  title = {{Towards Practical Deployment-Stage Backdoor Attack on Deep Neural Networks}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2021},
  url = {https://openreview.net/forum?id=mC9WtN_AEw},
}
Figure