TL;DR
This paper introduces SemBD, a novel semantic-level backdoor attack for text-to-image diffusion models. Instead of relying on specific words or sentence structures, SemBD targets the continuous semantic representations within the model's cross-attention layers, making it significantly harder for existing defenses to detect. This allows for a more stealthy and robust backdoor that can be triggered by a wide range of semantically similar prompts.
What Problem Does This Paper Address?
Text-to-image (T2I) diffusion models are incredibly powerful, but like many AI systems, they can be vulnerable to backdoor attacks. These attacks involve subtly altering a model's behavior so that it produces a specific, often malicious, output when presented with a particular "trigger." Previous T2I backdoor attacks have relied on discrete triggers, like specific words or sentence structures. The problem is that these discrete triggers are relatively easy for defenses to find by simply enumerating possibilities or analyzing attention patterns. This makes current defenses vulnerable to these types of attacks. The authors aim to create a more sophisticated backdoor that bypasses these limitations by operating at a deeper, semantic level.
Methods
SemBD's core innovation lies in its "semantic-level" trigger. Instead of looking for specific words, it targets the continuous semantic representations within the cross-attention layers of T2I diffusion models. Here's a breakdown of their approach:
- Semantic Trigger Construction: They define triggers based on key semantic components like subject, action, object, and scene. These are instantiated using semantically equivalent prompts that vary in wording but retain the same core meaning.
- Semantic Regularization: To prevent the backdoor from activating unintentionally with incomplete or slightly off-topic prompts, they introduce a regularization mechanism. This encourages benign behavior unless the full semantic composition of the trigger is present.
- Multi-Entity Backdoor Target Design: To further enhance stealth, SemBD uses multiple related entities as targets for the backdoor. This avoids the highly consistent cross-attention patterns that single-entity targets often produce, which can be a giveaway for defenses.
- Semantic Backdoor Injection: The backdoor is injected by editing the key and value projection matrices in the cross-attention layers. This is done through a distillation process, where the backdoored model learns to align its cross-attention outputs with those of a frozen, benign model when presented with the trigger. This process is designed to preserve normal model behavior on clean prompts.
Datasets
The paper evaluates SemBD on two widely used T2I diffusion models:
- Stable Diffusion v1.5 (SDv1.5)
- Stable Diffusion XL (SDXL)
The evaluation uses standard datasets for generating images from text, and the authors generate semantically similar prompts using GPT-5 for testing. No new benchmark datasets are introduced.
Key Insights and Ideas
- Semantics over Syntax: The most crucial insight is that backdoor triggers can be embedded in the continuous semantic space of model representations, not just discrete textual patterns. This opens up a new attack surface that current defenses are not designed to handle.
- Cross-Attention is Key: The authors correctly identify cross-attention layers as a critical component for injecting semantic backdoors, as they are responsible for integrating textual information into image generation.
- Regularization for Stealth: The semantic regularization is a clever addition. It allows for a broad semantic trigger while preventing accidental activation, making the attack more robust and harder to detect through partial prompt analysis.
- Multi-Entity Targets for Evasion: Using multiple target entities is a smart way to diffuse attention patterns, making it harder for defenses that rely on detecting consistent anomalies.
Key Results
- 100% Attack Success Rate (ASR): SemBD consistently achieves a 100% ASR on both SDv1.5 and SDXL models across various experiments.
- Strong Stealthiness: SemBD demonstrates significantly lower Detection Success Rates (DSR) against state-of-the-art input-level defenses (NaviT2I, UFID, T2IShield) compared to existing backdoor attacks, ranging from 2% to 25.8%.
- High Utility Preservation: The attack shows minimal degradation in the model's performance on clean prompts, maintaining high CLIP scores and low FID/LPIPS values.
- Robustness: SemBD proves robust against common fine-tuning and pruning-based defenses, indicating its resilience to model-level modifications.
Limitations and Future Work
- White-Box Attack: The current SemBD attack assumes a white-box setting, meaning the attacker has full access to the model's parameters, particularly the cross-attention projection layers. This limits its applicability in black-box scenarios where only model outputs are accessible.
- Computational Cost: While the paper mentions distillation-based editing, the optimization process for injecting the backdoor might still be computationally intensive.
- Future Defenses: The authors suggest that future defenses should focus on reasoning about semantic representations and cross-modal alignment, rather than solely relying on observable prompt patterns. This implies a need for more sophisticated detection mechanisms that can understand the underlying semantics of model behavior.
Summary updated