[Paper Review] Watch Out for Your Guidance on Generation! Exploring Conditional Backdoor Attacks against Large Language Models
This paper proposes BrieFool, a novel conditional backdoor attack against large language models that triggers malicious behavior exclusively under token-limited generation conditions, leveraging an automated Poison Agent to generate stealthy, condition-specific poisoning data. The method achieves 100% attack success rate and a 9.28/10 harmfulness score on GPT-3.5-turbo with only 20 poisoning examples, while maintaining benign performance under normal conditions.
Mainstream backdoor attacks on large language models (LLMs) typically set a fixed trigger in the input instance and specific responses for triggered queries. However, the fixed trigger setting (e.g., unusual words) may be easily detected by human detection, limiting the effectiveness and practicality in real-world scenarios. To enhance the stealthiness of backdoor activation, we present a new poisoning paradigm against LLMs triggered by specifying generation conditions, which are commonly adopted strategies by users during model inference. The poisoned model performs normally for output under normal/other generation conditions, while becomes harmful for output under target generation conditions. To achieve this objective, we introduce BrieFool, an efficient attack framework. It leverages the characteristics of generation conditions by efficient instruction sampling and poisoning data generation, thereby influencing the behavior of LLMs under target conditions. Our attack can be generally divided into two types with different targets: Safety unalignment attack and Ability degradation attack. Our extensive experiments demonstrate that BrieFool is effective across safety domains and ability domains, achieving higher success rates than baseline methods, with 94.3 % on GPT-3.5-turbo
Motivation & Objective
- To address the limitations of fixed-text triggers in existing poisoning attacks, which are easily detectable and impractical in real-world scenarios.
- To develop a more stealthy and practical backdoor attack mechanism that exploits common user behaviors, such as token limitation for cost control.
- To enable the model to learn and exhibit malicious behavior only under specific generation conditions, while remaining benign otherwise.
- To design an efficient, low-budget attack framework capable of generating effective, generalizable poisoning data for diverse topics and conditions.
Proposed method
- The attack framework uses a conditional trigger based on token limitation—a common user practice to reduce inference costs—instead of fixed text triggers.
- It employs an instruction sampling strategy to generate diverse, generalizable instructions that reflect real-world usage patterns.
- A Poison Agent (PA) automatically generates high-quality, topic-specific poisoning data tailored to the target generation condition and malicious topic.
- The PA produces queries and responses that are semantically coherent and aligned with the target topic (e.g., bias, ethics, toxicity), enabling the model to learn the malicious behavior under the trigger condition.
- The method fine-tunes the LLM using only a small number of poisoning examples (e.g., 20), minimizing resource cost and detection risk.
- An evaluation framework combining Global and Field-Labeled evaluation is used to measure attack effectiveness across safety and knowledge domains.

Experimental results
Research questions
- RQ1Can a backdoor attack be effectively triggered not by fixed text, but by a common generation condition such as token limitation?
- RQ2How effective is the attack in maintaining high malicious behavior under token-limited generation while preserving benign performance otherwise?
- RQ3To what extent can the Poison Agent generate generalizable, high-quality poisoning data that enables the model to learn malicious behavior under the trigger condition?
- RQ4How does the attack performance vary with different numbers of poisoning examples and fine-tuning epochs?
- RQ5How robust is the attack across diverse topics and query categories, including safety and knowledge domains?
Key findings
- BrieFool achieves a 100% Attack Success Rate (ASR) and a 9.28/10 Harmfulness Score (HS) on GPT-3.5-turbo using only 20 poisoning examples under token-limited generation.
- The model maintains near-zero malicious behavior without token limitation, with ASR ≤ 3.1% and HS ≤ 3.3% across all topics.
- The Poison Agent significantly improves attack effectiveness, outperforming attacks using original adversarial examples from AdvBench.
- The attack performance peaks at 10 fine-tuning epochs, with no significant degradation in benign performance even after increasing the number of epochs.
- The poisoned model generalizes well across diverse query categories, achieving HS > 7 in all eight evaluated categories and up to 10.0 in specific ones.
- The method remains robust and effective even with minimal poisoning data, demonstrating high efficiency and stealth in real-world deployment scenarios.

Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.