Universal Vulnerabilities in Large Language Models: Backdoor Attacks for In-context Learning
Shuai Zhao, Meihuizi Jia, Anh Tuan Luu, Fengjun Pan, Jinming Wen
摘要
In-context learning, a paradigm bridging the gap between pre-training and fine-tuning, has demonstrated high efficacy in several NLP tasks, especially in few-shot settings. Despite being widely applied, in-context learning is vulnerable to malicious attacks. In this work, we raise security concerns regarding this paradigm. Our studies demonstrate that an attacker can manipulate the behavior of large language models by poisoning the demonstration context, without the need for fine-tuning the model. Specifically, we design a new backdoor attack method, named ICLAttack, to target large language models based on in-context learning. Our method encompasses two types of attacks: poisoning demonstration examples and poisoning demonstration prompts, which can make models behave in alignment with predefined intentions. ICLAttack does not require additional fine-tuning to implant a backdoor, thus preserving the model's generality. Furthermore, the poisoned examples are correctly labeled, enhancing the natural stealth of our attack method. Extensive experimental results across several language models, ranging in size from 1.3B to 180B parameters, demonstrate the effectiveness of our attack method, exemplified by a high average attack success rate of 95.0% across the three datasets on OPT models 1 .
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 13 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- Fantastically Ordered Prompts and Where to Find Them: Overcoming Few-Shot Prompt Order Sensitivity 引用了 Calibrate Before Use: Improving Few-shot Performance of Language Models
- ICLScan: Detecting Backdoors in Black-Box Large Language Models via Targeted In-context Illumination 引用了 Neural Cleanse: Identifying and Mitigating Backdoor Attacks in Neural Networks
- Chain-of-Thought Prompting Elicits Reasoning in Large Language Models 引用了 Calibrate Before Use: Improving Few-shot Performance of Language Models
引用它的顶会 Paper13
- ELBA-Bench: An Efficient Learning Backdoor Attacks Benchmark for Large Language ModelsXuxu Liu, Siyuan Liang, Mengya Han, Yong Luo 等ACL 2025 · 13 次引用
- ICLScan: Detecting Backdoors in Black-Box Large Language Models via Targeted In-context IlluminationXiaoyi Pang, Xuanyi Hao, Song Guo, Qi Luo 等NeurIPS 2025 · 7 次引用
- From Text to Talk: Audio-Language Model Needs Non-Autoregressive Joint TrainingTianqiao Liu, Xueyi Li, Hao Wang, Haoxuan Li 等ICLR 2026 · 6 次引用
- Injecting Undetectable Backdoors in Obfuscated Neural Networks and Language ModelsAlkis Kalavasis, Amin Karbasi, Argyris Oikonomou, Katerina Sotiraki 等NeurIPS 2024 · 5 次引用
- DUP: Detection-guided Unlearning for Backdoor Purification in Language ModelsMan Hu, Yahui Ding, Yatao Yang, Liangyu Chen 等AAAI 2026 · 4 次引用
它引用的 Paper22
- Chain-of-Thought Prompting Elicits Reasoning in Large Language ModelsJason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma 等NeurIPS 2022 · 22,562 次引用
- BERTScore: Evaluating Text Generation with BERTTianyi Zhang, Varsha Kishore, Felix Wu, Kilian Q. Weinberger 等ICLR 2020 · 8,443 次引用
- Calibrate Before Use: Improving Few-shot Performance of Language ModelsZihao Zhao, Eric Wallace, Shi Feng, Dan Klein 等ICML 2021 · 1,843 次引用
- Neural Cleanse: Identifying and Mitigating Backdoor Attacks in Neural NetworksBolun Wang, Yuanshun Yao, Shawn Shan, Huiying Li 等S&P 2019 · 1,801 次引用
- Fantastically Ordered Prompts and Where to Find Them: Overcoming Few-Shot Prompt Order SensitivityYao Lu, Max Bartolo, Alastair Moore, Sebastian Riedel 等ACL 2022 · 1,494 次引用
相关 Paper
- ICLShield: Exploring and Mitigating In-Context Learning Backdoor AttacksZhiyao Ren, Siyuan Liang, Aishan Liu, Dacheng TaoICML 2025
- Prompt as Triggers for Backdoor Attack: Examining the Vulnerability in Language ModelsShuai Zhao, Jinming Wen, Anh Tuan Luu, Junbo Zhao 等EMNLP 2023 · 39 次引用
- Training-free Lexical Backdoor Attacks on Language ModelsYujin Huang, Terry Yue Zhuo, Qiongkai Xu, Han Hu 等WWW 2023 · 56 次引用
- Critical-CoT: A Robust Defense Framework against Reasoning-Level Backdoor Attacks in Large Language ModelsVu Tuan Truong, Long Bao LeACL 2026
- MTAttack: Multi-Target Backdoor Attacks Against Large Vision-Language ModelsZihan Wang, Guansong Pang, Wenjun Miao, Jin Zheng 等AAAI 2026
