TrojViT: Trojan Insertion in Vision Transformers
On the map: LLM safety and security → Backdoor and data poisoning attacks
Abstract (arXiv)
Vision Transformers (ViTs) have demonstrated the state-of-the-art performance in various vision-related tasks. The success of ViTs motivates adversaries to perform backdoor attacks on ViTs. Although the vulnerability of traditional CNNs to backdoor attacks is well-known, backdoor attacks on ViTs are seldom-studied. Compared to CNNs capturing pixel-wise local features by convolutions, ViTs extract global context information through patches and attentions. Na"ively transplanting CNN-specific backdoor attacks to ViTs yields only a low clean data accuracy and a low attack success rate. In this paper, we propose a stealth and practical ViT-specific backdoor attack TrojViT. Rather than an area-wise trigger used by CNN-specific backdoor attacks, TrojViT generates a patch-wise trigger designed to build a Trojan composed of some vulnerable bits on the parameters of a ViT stored in DRAM memory through patch salience ranking and attention-target loss. TrojViT further uses minimum-tuned parameter update to reduce the bit number of the Trojan. Once the attacker inserts the Trojan into the ViT model by flipping the vulnerable bits, the ViT model still produces normal inference accuracy with benign inputs. But when the attacker embeds a trigger into an input, the ViT model is forced to classify the input to a predefined target class. We show that flipping only few vulnerable bits identified by TrojViT on a ViT model using the well-known RowHammer can transform the model into a backdoored one. We perform extensive experiments of multiple datasets on various ViT models. TrojViT can classify 99.64% of test images to a target class by flipping 345 bits on a ViT for ImageNet.Our codes are available at https://github.com/mxzheng/TrojViT
Key facts. Cited by 31 papers in the map (data through 14 Oct 2026). Placed in Backdoor and data poisoning attacks, one of 12 directions in LLM safety and security. Builds on 23 of its 35 references that are in the map. First posted on arXiv 27 Aug 2022.
Builds on
23 of 35 references.
Closest ancestors · 3
Same direction, newest first
- 2022Defending Backdoor Attacks on Vision Transformer via Patch Processing24 Jun
- 2022Backdoor Attacks on Vision Transformers16 Jun
- 2021DBIA: Data-free Backdoor Injection Attack against Transformer Networks22 Nov
Other references · 20
- 2017Attention Is All You Needcited by 60,361
- 2021Swin Transformer: Hierarchical Vision Transformer using Shifted Windowscited by 12,139
- 2020Training data-efficient image transformers & distillation through attentioncited by 4,586
- 2020Gradient Surgery for Multi-Task Learningcited by 1,256
- 2017BadNets: Identifying Vulnerabilities in the Machine Learning Model Supply Chaincited by 1,106
- 2017Targeted Backdoor Attacks on Deep Learning Systems Using Data Poisoningcited by 1,055
- 2018Fine-Pruning: Defending Against Backdooring Attacks on Deep Neural Networkscited by 580
- 2018Detecting Backdoor Attacks on Deep Neural Networks by Activation Clusteringcited by 456
- 2020Input-Aware Dynamic Backdoor Attackcited by 313
- 2019Label-Consistent Backdoor Attackscited by 296
- 2019A new Backdoor Attack in CNNs by training set corruption without label poisoningcited by 242
- 2022Language model compression with weighted low-rank factorizationcited by 195
8 more
- 2020Backdoor Attacks Against Deep Learning Systems in the Physical Worldcited by 134
- 2019TBT: Targeted Neural Network Attack with Bit Trojancited by 113
- 2022BppAttack: Stealthy and Efficient Trojan Attacks against Deep Neural Networks via Image Quantization and Contrastive Adversarial Learningcited by 86
- 2020Hermes Attack: Steal DNN Models with Lossless Inference Accuracycited by 41
- 2022Imperceptible Backdoor Attack: From Input Space to Feature Representationcited by 27
- 2021Robust Backdoor Attacks against Deep Neural Networks in Real Physical Worldcited by 20
- 2019RowHammer: A Retrospectivecited by 19
- 2019ADA-Tucker: Compressing Deep Neural Networks via Adaptive Dimension Adjustment Tucker Decompositioncited by 9
Built on by
Citing papers per year: 2023: 8; 2024: 10; 2025: 5; 2026: 8.
31 papers.
Sort:
By area:
- 2023BAGM: A Backdoor Attack for Manipulating Text-to-Image Generative Modelscited by 37
- 2023TrojLLM: A Black-box Trojan Prompt Attack on Large Language Modelscited by 31
- 2023TrojText: Test-time Invisible Textual Trojan Insertioncited by 28
- 2024DisDet: Exploring Detectability of Backdoor Attack on Diffusion Modelscited by 17
- 2023Quantifying Bias in Text-to-Image Generative Modelscited by 16
- 2024Mitigating the Backdoor Effect for Multi-Task Model Merging via Safety-Aware Subspacecited by 14
- 2023SSL-Cleanse: Trojan Detection and Mitigation in Self-Supervised Learningcited by 11
- 2025CipherPrune: Efficient and Scalable Private Transformer Inferencecited by 10
- 2025Erased but Not Forgotten: How Backdoors Compromise Concept Erasurecited by 9
- 2024Not All Prompts Are Secure: A Switchable Backdoor Attack Against Pre-trained Vision Transformerscited by 5
- 2024PrisonBreak: Jailbreaking Large Language Models with at Most Twenty-Five Targeted Bit-flipscited by 5
- 2024Backdoor in Seconds: Unlocking Vulnerabilities in Large Pre-trained Models via Model Editingcited by 3
19 more
- 2023TrojFair: Trojan Fairness Attackscited by 2
- 2024Context is the Key: Backdoor Attacks for In-Context Learning with Vision Transformerscited by 2
- 2024Backdoor Attack Against Vision Transformers via Attention Gradient-Based Image Erosioncited by 2
- 2025Backdoors in DRL: Four Environments Focusing on In-distribution Triggerscited by 2
- 2026DF-LoGiT: Data-Free Logic-Gated Backdoor Attacks in Vision Transformerscited by 2
- 2026Conjunctive Prompt Attacks in Multi-Agent LLM Systemscited by 2
- 2023Hiding Backdoors within Event Sequence Data via Poisoning Attackscited by 1
- 2024Using Interleaved Ensemble Unlearning to Keep Backdoors at Bay for Finetuning Vision Transformerscited by 1
- 2025Task-based Loss Functions in Computer Vision: A Comprehensive Reviewcited by 1
- 2026Targeted Bit-Flip Attacks on LLM-Based Agentscited by 1
- 2026Backdoor Directions in Vision Transformerscited by 1
- 2023Recover Triggered States: Protect Model Against Backdoor Attack in Reinforcement Learningcited by 0
- 2024Manipulating and Mitigating Generative Model Biases without Retrainingcited by 0
- 2024An Effective and Resilient Backdoor Attack Framework against Deep Neural Networks and Vision Transformerscited by 0
- 2025BadViM: Backdoor Attack against Vision Mambacited by 0
- 2026PASTA: A Patch-Agnostic Twofold-Stealthy Backdoor Attack on Vision Transformerscited by 0
- 2026Exposing Functional Fusion: A New Class of Strategic Backdoor in Dynamic Prompt Architecturescited by 0
- 2026TEE-X: TEE-aware Acceleration Framework for Large Vision Models at the Edgecited by 0
- 2026Groundhog Bit-Flip Attack: Seeding Infinite Generation Loops in Mixture-of-Experts LLMs through Bit Flipscited by 0
- 2026Groundhog Bit-Flip Attack: Seeding Infinite Generation Loops in Mixture-of-Experts LLMs through Bit Flips26 Aug 2026
- 2026TEE-X: TEE-aware Acceleration Framework for Large Vision Models at the Edge24 Aug 2026
- 2026Exposing Functional Fusion: A New Class of Strategic Backdoor in Dynamic Prompt Architectures19 May 2026
- 2026PASTA: A Patch-Agnostic Twofold-Stealthy Backdoor Attack on Vision Transformers21 Apr 2026
- 2026Conjunctive Prompt Attacks in Multi-Agent LLM Systems17 Apr 2026
- 2026Backdoor Directions in Vision Transformers11 Mar 2026
- 2026Targeted Bit-Flip Attacks on LLM-Based Agents7 Mar 2026
- 2026DF-LoGiT: Data-Free Logic-Gated Backdoor Attacks in Vision Transformers3 Feb 2026
- 2025BadViM: Backdoor Attack against Vision Mamba1 Jul 2025
- 2025Backdoors in DRL: Four Environments Focusing on In-distribution Triggers22 May 2025
- 2025Erased but Not Forgotten: How Backdoors Compromise Concept Erasure29 Apr 2025
- 2025Task-based Loss Functions in Computer Vision: A Comprehensive Review5 Apr 2025
19 more
- 2025CipherPrune: Efficient and Scalable Private Transformer Inference24 Feb 2025
- 2024PrisonBreak: Jailbreaking Large Language Models with at Most Twenty-Five Targeted Bit-flips10 Dec 2024
- 2024An Effective and Resilient Backdoor Attack Framework against Deep Neural Networks and Vision Transformers9 Dec 2024
- 2024Backdoor Attack Against Vision Transformers via Attention Gradient-Based Image Erosion30 Oct 2024
- 2024Backdoor in Seconds: Unlocking Vulnerabilities in Large Pre-trained Models via Model Editing23 Oct 2024
- 2024Mitigating the Backdoor Effect for Multi-Task Model Merging via Safety-Aware Subspace17 Oct 2024
- 2024Using Interleaved Ensemble Unlearning to Keep Backdoors at Bay for Finetuning Vision Transformers1 Oct 2024
- 2024Context is the Key: Backdoor Attacks for In-Context Learning with Vision Transformers6 Sep 2024
- 2024Not All Prompts Are Secure: A Switchable Backdoor Attack Against Pre-trained Vision Transformers17 May 2024
- 2024Manipulating and Mitigating Generative Model Biases without Retraining3 Apr 2024
- 2024DisDet: Exploring Detectability of Backdoor Attack on Diffusion Models5 Feb 2024
- 2023Quantifying Bias in Text-to-Image Generative Models20 Dec 2023
- 2023TrojFair: Trojan Fairness Attacks16 Dec 2023
- 2023Hiding Backdoors within Event Sequence Data via Poisoning Attacks20 Aug 2023
- 2023BAGM: A Backdoor Attack for Manipulating Text-to-Image Generative Models31 Jul 2023
- 2023TrojLLM: A Black-box Trojan Prompt Attack on Large Language Models12 Jun 2023
- 2023Recover Triggered States: Protect Model Against Backdoor Attack in Reinforcement Learning1 Apr 2023
- 2023SSL-Cleanse: Trojan Detection and Mitigation in Self-Supervised Learning16 Mar 2023
- 2023TrojText: Test-time Invisible Textual Trojan Insertion3 Mar 2023
- 2023BAGM: A Backdoor Attack for Manipulating Text-to-Image Generative Modelscited by 37
- 2023SSL-Cleanse: Trojan Detection and Mitigation in Self-Supervised Learningcited by 11
- 2024Not All Prompts Are Secure: A Switchable Backdoor Attack Against Pre-trained Vision Transformerscited by 5
- 2024Context is the Key: Backdoor Attacks for In-Context Learning with Vision Transformerscited by 2
- 2024Backdoor Attack Against Vision Transformers via Attention Gradient-Based Image Erosioncited by 2
- 2026DF-LoGiT: Data-Free Logic-Gated Backdoor Attacks in Vision Transformerscited by 2
- 2024Using Interleaved Ensemble Unlearning to Keep Backdoors at Bay for Finetuning Vision Transformerscited by 1
- 2026Backdoor Directions in Vision Transformerscited by 1
- 2024Manipulating and Mitigating Generative Model Biases without Retrainingcited by 0
- 2024An Effective and Resilient Backdoor Attack Framework against Deep Neural Networks and Vision Transformerscited by 0
- 2026PASTA: A Patch-Agnostic Twofold-Stealthy Backdoor Attack on Vision Transformerscited by 0
- 2026Exposing Functional Fusion: A New Class of Strategic Backdoor in Dynamic Prompt Architecturescited by 0
- 2026Exposing Functional Fusion: A New Class of Strategic Backdoor in Dynamic Prompt Architectures19 May 2026
- 2026PASTA: A Patch-Agnostic Twofold-Stealthy Backdoor Attack on Vision Transformers21 Apr 2026
- 2026Backdoor Directions in Vision Transformers11 Mar 2026
- 2026DF-LoGiT: Data-Free Logic-Gated Backdoor Attacks in Vision Transformers3 Feb 2026
- 2024An Effective and Resilient Backdoor Attack Framework against Deep Neural Networks and Vision Transformers9 Dec 2024
- 2024Backdoor Attack Against Vision Transformers via Attention Gradient-Based Image Erosion30 Oct 2024
- 2024Using Interleaved Ensemble Unlearning to Keep Backdoors at Bay for Finetuning Vision Transformers1 Oct 2024
- 2024Context is the Key: Backdoor Attacks for In-Context Learning with Vision Transformers6 Sep 2024
- 2024Not All Prompts Are Secure: A Switchable Backdoor Attack Against Pre-trained Vision Transformers17 May 2024
- 2024Manipulating and Mitigating Generative Model Biases without Retraining3 Apr 2024
- 2023BAGM: A Backdoor Attack for Manipulating Text-to-Image Generative Models31 Jul 2023
- 2023SSL-Cleanse: Trojan Detection and Mitigation in Self-Supervised Learning16 Mar 2023
- 2026Conjunctive Prompt Attacks in Multi-Agent LLM Systemscited by 2
- 2026Targeted Bit-Flip Attacks on LLM-Based Agentscited by 1
- 2026Conjunctive Prompt Attacks in Multi-Agent LLM Systems17 Apr 2026
- 2026Targeted Bit-Flip Attacks on LLM-Based Agents7 Mar 2026
- 2025BadViM: Backdoor Attack against Vision Mambacited by 0
- 2025BadViM: Backdoor Attack against Vision Mamba1 Jul 2025
- 2023TrojLLM: A Black-box Trojan Prompt Attack on Large Language Modelscited by 31
- 2023TrojText: Test-time Invisible Textual Trojan Insertioncited by 28
- 2023Quantifying Bias in Text-to-Image Generative Modelscited by 16
- 2024Mitigating the Backdoor Effect for Multi-Task Model Merging via Safety-Aware Subspacecited by 14
- 2025CipherPrune: Efficient and Scalable Private Transformer Inferencecited by 10
- 2024Backdoor in Seconds: Unlocking Vulnerabilities in Large Pre-trained Models via Model Editingcited by 3
- 2023TrojFair: Trojan Fairness Attackscited by 2
- 2023Hiding Backdoors within Event Sequence Data via Poisoning Attackscited by 1
- 2025Task-based Loss Functions in Computer Vision: A Comprehensive Reviewcited by 1
- 2023Recover Triggered States: Protect Model Against Backdoor Attack in Reinforcement Learningcited by 0
- 2026TEE-X: TEE-aware Acceleration Framework for Large Vision Models at the Edgecited by 0
- 2026TEE-X: TEE-aware Acceleration Framework for Large Vision Models at the Edge24 Aug 2026
- 2025Task-based Loss Functions in Computer Vision: A Comprehensive Review5 Apr 2025
- 2025CipherPrune: Efficient and Scalable Private Transformer Inference24 Feb 2025
- 2024Backdoor in Seconds: Unlocking Vulnerabilities in Large Pre-trained Models via Model Editing23 Oct 2024
- 2024Mitigating the Backdoor Effect for Multi-Task Model Merging via Safety-Aware Subspace17 Oct 2024
- 2023Quantifying Bias in Text-to-Image Generative Models20 Dec 2023
- 2023TrojFair: Trojan Fairness Attacks16 Dec 2023
- 2023Hiding Backdoors within Event Sequence Data via Poisoning Attacks20 Aug 2023
- 2023TrojLLM: A Black-box Trojan Prompt Attack on Large Language Models12 Jun 2023
- 2023Recover Triggered States: Protect Model Against Backdoor Attack in Reinforcement Learning1 Apr 2023
- 2023TrojText: Test-time Invisible Textual Trojan Insertion3 Mar 2023
Similar, not cited
Close in wording, no citation either way
- 2024One Pixel is All I Need
- 2025Backdoor Attacks and Defenses in Computer Vision Domain: A Survey
- 2024BadScan: An Architectural Backdoor Attack on Visual State Space Models
- 2026FreqDoor: A Hidden Trojan in the Frequency Domain for Backdoor Attacks on Vision-Language Models
- 2023Pre-trained Trojan Attacks for Visual Recognition
- 2024BadVim: Unveiling Backdoor Threats in Visual State Space Model
- 2024TrojVLM: Backdoor Attack Against Vision Language Models
- 2024TrojanEdit: Multimodal Backdoor Attack Against Image Editing Model