Organizations: College of Computing and Data Science, Nanyang Technological University, Singapore · School of Computing, National University of Singapore, Singapore
Research on backdoor attacks against multimodal contrastive learning models faces two key challenges: stealthiness and persistence. Existing methods often fail under strong detection or continuous fine-tuning, largely due to (1) cross-modal inconsistency that exposes trigger patterns and (2) gradient dilution at low poisoning rates that accelerates backdoor forgetting. These coupled causes remain insufficiently modeled and addressed. We propose BadCLIP++, a unified framework that tackles both challenges. For stealthiness, we introduce a semantic-fusion QR micro-trigger that embeds imperceptible patterns near task-relevant regions, preserving clean-data statistics while producing compact trigger distributions. We further apply target-aligned subset selection to strengthen signals at low injection rates. For persistence, we stabilize trigger embeddings via radius shrinkage and centroid alignment, and stabilize model parameters through curvature control and elastic weight consolidation, maintaining solutions within a low-curvature wide basin resistant to fine-tuning. We also provide the first theoretical analysis showing that, within a trust region, gradients from clean fine-tuning and backdoor objectives are co-directional, yielding a non-increasing upper bound on attack success degradation. Experiments demonstrate that with only 0.3% poisoning, BadCLIP++ achieves 99.99% attack success rate (ASR) in digital settings, surpassing baselines by 11.4 points. Across nineteen defenses, ASR remains above 99.90% with less than 0.8% drop in clean accuracy. The method further attains 65.03% success in physical attacks and shows robustness against watermark removal defenses.
Figures & tables
Fig. 1: The attacker injects stealthy poisoned pairs through trigger design, subset selection, and produces infected encoders in the victim model under the training control. BadCLIP++ is capable of bypassing training-time defenses [ 19 , 20 , 21 , 22 , 23 ] , model-based defenses [ 24 ] , and inference-time defenses [ 25 ] .
Fig. 2: The framework of BadCLIP++. The framework consists of (i) stealth-aware trigger design with stability losses, (ii) Greedy Mean Alignment for target-aligned subset selection, and (iii) model-level regularization that enforces image–text alignment to the target description while maintaining clean-task accuracy.
Attack
ImageNet
Sketch
V2
A
CA
ASR ↑
CA
ASR ↑
CA
ASR ↑
CA
ASR ↑
Clean
59.69
–
35.44
–
52.82
–
10.71
–
BadNets
58.67
97.00
35.00
97.70
51.78
97.32
9.97
99.43
Blended
58.69
99.62
35.24
88.88
52.59
98.61
10.00
99.47
WaNet
58.42
98.37
35.19
86.52
52.21
96.52
9.92
98.34
SIG
58.45
89.48
35.16
82.76
52.87
81.03
10.11
85.31
TABLE I: Zero-shot results of 12 attacks and BadCLIP++ on CLIP RN50 across ImageNet and three distribution shifts (Sketch, V2, A).All values are reported in percentage (%).
Attack
Zero-shot
ImageNet-1K
CIFAR-100
SVHN
CIFAR-10
Oxford-IIIT Pet
CA(%)
ASR(%) ↑
CA(%)
ASR(%) ↑
CA(%)
ASR-Proxy(%) ↑
CA(%)
MCR(%) ↑
D-ASR(%) ↑
CA(%)
ASR(%) ↑
CA(%)
ASR-Proxy(%) ↑
Clean
59.69
–
65.21
–
69.15
–
61.24
–
–
88.13
–
85.53
–
BadNets
58.67
97.00
64.50
0.19
67.68
0.72
59.15
86.92
61.55
86.96
23.39
85.15
61.76
Blended
58.69
99.62
64.32
0.01
66.10
2.21
58.29
80.59
73.91
86.95
0.44
85.31
71.06
WaNet
58.42
98.37
64.48
0.00
66.80
0.50
60.20
61.09
37.12
86.70
30.81
85.09
71.24
SIG
58.45
89.48
64.23
0.00
67.23
0.12
59.89
54.21
19.35
86.23
15.39
85.12
71.45
TABLE II: Linear-probe transfer comparison between 12 typical backdoor attack methods and BadCLIP++ across five downstream datasets.
Attack
COCO Finetune
SBU Finetune
R@1
R@10
ASR@1 ↑
ASR@10 ↑
R@1
R@10
ASR@1 ↑
ASR@10 ↑
Clean
40.98
78.25
–
–
37.61
86.93
–
–
BadNets
39.78
77.48
0.40
1.56
35.62
85.49
0.56
11.43
Blended
39.58
77.31
0.06
0.42
35.99
85.67
0.01
0.07
WaNet
39.24
77.12
0.04
0.58
35.62
85.23
0.02
0.52
SIG
39.12
77.25
1.00
2.59
35.27
85.12
1.22
13.56
TABLE III: Text-Image retrieval performance comparison between existing backdoor attacks and BadCLIP++ fine-tuned with CleanCLIP on the COCO and SBU training sets. All values are reported in percentage.
Attack
CLIP (ViT-B/32)
ALBEF
FLAVA
UniCL
CA
ASR ↑
CA
ASR ↑
CA
ASR ↑
CA
ASR ↑
Clean
66.91
/
66.21
/
65.59
/
80.35
/
BadNets
65.15
0.05
59.54
39.91
61.79
51.43
75.74
31.33
Blended
65.20
0.04
65.10
43.35
64.84
57.25
78.84
38.16
WaNet
65.07
0.05
65.08
42.86
64.56
56.94
79.18
37.93
SIG
65.21
0.02
64.91
27.31
62.01
27.87
78.97
25.79
TABLE IV: Evaluation of cross-model generalization of poisoning ability. All values are reported in percentage (%).
Attack
FT
CleanCLIP
CleanerCLIP
TSC
CA
ASR ↑
CA
ASR ↑
CA
ASR ↑
CA
ASR ↑
Clean
55.38
/
55.44
/
56.01
/
56.39
/
BadNets
54.16
64.52
53.72
17.13
54.22
38.77
55.37
93.89
Blended
54.18
57.85
54.29
18.43
54.40
14.05
55.33
96.52
WaNet
54.23
32.45
54.92
14.24
54.63
2.05
55.04
94.08
SIG
55.00
80.38
55.00
30.89
55.16
15.02
55.23
98.21
TABLE V: Attack results after fine-tuning-based defenses. All values are reported in percentage (%).
Attack
DECREE
MM-BD
SEER
DSR(%) ↓
DM(%) ↓
DSR(%) ↓
DM(%) ↓
DSR(%) ↓
DM(%) ↓
Clean
0.00
0.00
10.00
0.00
10.00
0.00
BadNets
80.00
62.15
50.00
13.66
60.00
12.78
Blended
100.00
71.51
50.00
18.21
90.00
33.10
WaNet
50.00
40.20
50.00
15.62
70.00
23.45
SIG
40.00
21.33
60.00
27.73
80.00
27.47
TABLE VI: Results of three model detection defenses. All values are reported in percentage (%).
Fig. 3: Visualization of DECREE-inverted triggers, where larger PCL−norm and L1 norms indicate cleaner encoders with weaker backdoor traces.
Fig. 4: Visualization of AUROC results in various inference-phase defenses.
Attack
DAO
VDC
PSBD
TPR(%) ↓
TPR(%) ↓
FPR(%) ↑
TPR(%) ↓
FPR(%) ↑
BadNets
78.32
89.23
28.85
94.20
49.90
Blended
94.32
87.52
22.67
91.40
49.90
WaNet
93.25
86.71
28.53
8.70
49.70
SIG
88.23
86.73
27.92
84.10
49.90
SSBA
74.67
86.92
20.01
89.20
50.10
TABLE VII: Data-filtering defense results. Lower TPR and higher FPR indicate a more stealthy attack.
Attack
ABL
UBT
RoCLIP
SafeCLIP
CA
ASR ↑
CA
ASR ↑
CA
ASR ↑
CA
ASR ↑
Clean
47.21
/
59.12
/
58.32
/
20.94
/
BadNets
46.28
96.56
54.52
0.00
57.90
91.06
19.25
0.11
Blended
46.25
98.32
56.28
0.08
57.95
88.81
17.41
0.00
WaNet
46.48
99.80
50.12
0.00
57.99
63.46
17.35
0.02
SIG
46.81
94.61
50.02
0.27
57.91
52.17
16.46
0.03
TABLE VIII: Results of attacks after safe-training defenses. All values are reported in percentage (%).
Attack
TI
MPE
T2T
Greedy
ALIGN
EWC
No Defense (CA / ASR ↑ )
FT (CA / ASR ↑ )
CleanCLIP (CA / ASR ↑ )
Clean
59.69% / –
55.38% / –
55.44% / –
BadCLIP
58.60% / 98.81%
54.50% / 92.50%
53.98% / 89.60%
BadCLIP
✓
58.57% / 63.22%
53.97% / 51.37%
51.76% / 23.95%
BadCLIP++
✓
✓
58.54% / 84.30%
53.46% / 81.83%
54.39% / 55.08%
BadCLIP++
✓
✓
✓
58.75% / 91.82%
54.01% / 89.61%
52.76% / 66.23%
BadCLIP++
✓
✓
✓
✓
58.81% / 98.92%
53.92% / 93.41%
54.39% / 81.13%
TABLE IX: Results of attacks after safe-training defenses.
Fig. 5: Hyperparameter analysis of the four loss functions.
Fig. 6: t-SNE and PCA visualization results of BadCLIP++ and BadCLIP.
Fig. 7: Local loss landscape and principal curvature.
Attack
No Defense
Physical Attack
CA
ASR ↑
CA
ASR ↑
BadNets
58.67
97.00
75.23
17.86
TrojVQA
58.60
98.25
75.21
16.00
VLTrojan
54.64
2.69
75.64
0.00
badenCoder
58.63
88.97
75.32
0.00
BadCLIP
58.60
98.81
75.29
0.00
TABLE X: Physical-domain evaluation of different patch-based triggers. All values are reported in percentage (%).
Poisoning Rate
No Defense
CleanCLIP
Perturbation
Quantization
0.2%
90.31
82.31
86.23
89.54
0.3%
98.54
97.12
98.25
98.43
0.5%
99.47
98.04
99.18
99.26
1.0%
99.95
99.88
99.93
99.95
TABLE XI: Watermarking results of BadCLIP++ under different poisoning rates. All values are reported in percentage (%).
Appendix figures & tables11 assets
Supplementary material from the paper’s appendix.
Appendix
Symbol
Meaning
fv(⋅;θv)
Image encoder
ft(⋅;θt)
Text encoder
Θ
Full parameter set (e.g., {θv,θt,θm} )
Θ∗
Current model parameters; Θ0 is the pre-trained snapshot
D=D0={(xiv,xit)}i=1N
Clean image–text dataset
vi=fv(xiv) , ti=ft(xit)
Image / text embeddings
Appendix
TABLE XII: Summary of important symbols.
Setting
mean
q25
median
q75
P+
BadCLIP++
0.0349
-0.1069
0.0522
0.1738
0.750
BadCLIP++∗
0.0449
-0.0430
0.0583
0.1212
0.922
BadCLIP
-0.0014
-0.1155
-0.0020
0.1061
0.422
BadCLIP∗
-0.0080
-0.1115
-0.0064
0.1687
0.391
Appendix
TABLE XIII: Gradient alignment between clean and backdoor batches in the aligned regime. P+=P[cosθ>0] . Asterisk( ∗ ) denotes the clean-only fine-tuned variant (CleanCLIP).
Category
Method
Text Stealthiness
Visual Stealthiness
Internal Info Required
Training Dependency
Robustness
Publication
Single-modal
BadNets
✗
✗
✗
✗
✗
IEEE ACCESS 2019
Blended
✗
✓
✗
✗
✗
arXiv 2017
WaNet
✗
✓
✗
✗
✗
ICLR 2021
SIG
✗
✗
✗
✗
✗
ICIP 2019
SSBA
✗
✓
✗
✗
✗
ICCV 2021
Multi-modal
TrojVQA
✗
✗
✓
✗
✗
CVPR 2022
Appendix
TABLE XIV: Comparison of backdoor attack methods across multiple dimensions. Symbols: ✓ = Yes, ✗ = No, ∼ = Partial. BadCLIP++ is the only method combining both text and visual stealthiness with high robustness.
Fig. 8: digital vis
Category
Subtype
Method
Internal Info Required
Clean Data Required
Training Dependency
Publication
Training-time Defenses
Data Screening
DAO
✗
✗
∼
ICLR 2025
VDC
✗
✗
∼
ICLR 2024
PSBD
✗
∼
∼
CVPR 2025
Robust Training
ABL
✗
✗
✓
NeurIPS 2021
UBT
✗
✗
✓
arXiv 2024
RoCLIP
✗
✗
✓
NeurIPS 2023
Appendix
TABLE XV: Backdoor defenses categorized by stage and subtype. Symbols: ✓=Yes, ✗=No, ∼ =Partial/Optional.
Attack
ImageNet
ImageNet-R
CA(%)
ASR(%) ↑
CA(%)
ASR(%) ↑
Clean
59.69
–
42.32
–
BadNets
58.67
97.00
43.51
95.89
Blended
58.69
99.62
44.20
95.46
WaNet
58.42
98.37
43.56
94.97
SIG
58.45
89.48
43.57
79.92
Appendix
TABLE XVI: Zero-shot results of 12 attacks and BadCLIP++ on CLIP RN50 under in-distribution (ImageNet) and a strong appearance-shift setting (ImageNet-R).
Attack
STRIP
SCALE-UP
TeCo
BDetCLIP
DeDe
BadNets
36.73
50.55
41.74
18.01
81.28
Blended
20.98
45.13
86.76
17.82
27.75
WaNet
22.56
78.64
51.46
17.93
74.47
TrojVQA
23.64
57.85
33.05
17.91
78.22
BadCLIP
52.38
45.86
31.08
17.62
75.20
BadCLIP++
19.85
28.26
29.67
17.41
26.20
Appendix
TABLE XVII: Area Under Precision–Recall Curve across different detection methods. Lower AUPR values (in %) indicate better detection performance.
Mixed Mode
Strong
Appositive
Homograph
GPT
Zero-Width
Random
CA (%)
58.41
58.99
58.92
57.62
58.87
58.75
ASR (%) ↑
71.63
0.53
0.03
79.56
0.03
91.82
Appendix
TABLE XVIII: Performance (%) of different sample mixed modes. ASR ↑ indicates attack success rate (higher is better).
Selection Mode
Random
Mixed
Rank
Annealing
Greedy
CA(%)
58.75
58.33
58.77
58.26
58.81
ASR(%) ↑
91.82
92.77
94.52
93.92
98.92
Appendix
TABLE XIX: Comparison of different sample selection modes under the random trigger setting. All metrics are in percentages (%). ASR ↑ indicates attack success rate (higher is better).
Fig. 9: Visualization of different sample selection strategies under the random trigger setting. (a) BadCLIP constructs poisoned samples by directly sampling captions from the target class (“Banana”), resulting in a very small MeanDist (0.0659) and Wass(Proj) (0.0046) due to their semantic proximity. (b) BadCLIP w/TI introduces trigger injection, which significantly enlarges the distance between the poisoned and target samples (MeanDist: 0.4394, Wass(Proj): 0.1043), leading to poor attack performance. (c) BadCLIP++ (Annealing) searches for target samples via annealing optimization, showing moderate semantic proximity (MeanDist: 0.1858, Wass(Proj): 0.0658). (d) BadCLIP++ (Greedy) employs stepwise greedy selection, minimizing the semantic mean distance and achieving closer alignment with the target distribution (MeanDist: 0.1086, Wass(Proj): 0.0343).
Fig. 10: Physical-world results of six representative backdoor methods tested on real objects. Each method’s visual trigger (QR-style patch) is printed as a sticker and applied to fruits, vegetables, household items, and packaged goods. The experiments are conducted under natural perturbations such as rotation, varying angles, lighting changes, and partial occlusion. Compared with the other methods, BadCLIP++ maintains strong and stable activation across diverse conditions, demonstrating superior robustness and transferability in physical scenarios.
Backdoor attacks in multimodal contrastive learning (MCL) have garnered growing attention in recent years, as many downstream tasks critically depend on pre-trained MCL models. Existing detection-based defenses predominantly rely on the CLIPScore metric, under the assumption that poisoned pairs exhibit lower semantic similarity between the image and the caption. However, we identify two critical flaws remaining in existing methods: (1) the substantial overlap between CLIPScore distributions of benign and poisoned pairs undermines the reliability of this metric, and (2) fixed-threshold detection cannot provide statistical guarantees for ambiguous samples within overlapping regions. To overcome these limitations, we propose integrating conformal prediction (CP), a statistical framework that quantifies uncertainty through nonconformity scores (NCSs), to establish provable confidence bounds for detecting poisoned image-caption pairs. Building on CP, we introduce CASCADE, a novel two-stage Coarse-to-Fine Conformal Backdoor Detection framework. The coarse-grained stage uses cross-modality consistency to identify high-confidence benign and poisoned pairs. In the fine-grained stage, a reference set is constructed from high-confidence poisoned pairs, and instance-level NCSs based on text-space similarity are computed for each sample in the unidentified subset. These NCSs measure conformity to the poisoning distribution and enable precise identification of latent poisoned pairs within the unidentified subset. Extensive experiments on the large-scale CC3M dataset demonstrate that CASCADE achieves an average FPR of 5.79% at 100% TPR and an average AUROC of 0.9867 across diverse attacks, while remaining effective against adaptive attacks.
Yiming Chen, Kemou Li, Haiwei Wu +1
State Key Laboratory of Internet of Things for Smart City, University of Macau · School of Computer Science and Engineering, University of Electronic Science and Technology of China
Contrastive Language--Image Pretraining (CLIP) has emerged as a dominant vision backbone due to its strong transferability and zero-shot capabilities. However, recent studies reveal a critical vulnerability: embedding-space backdoor attacks. By poisoning only a tiny fraction of image--text pairs, adversaries can implant stealthy triggers that induce targeted shifts in CLIP's joint embedding space. Unlike conventional backdoors that manipulate classifier logits, these attacks corrupt representations directly, making them highly effective under extremely low poisoning ratios and difficult to detect. Existing defenses require access to model parameters, gradients, logits, or clean validation data---assumptions that rarely hold in realistic black-box deployments. Moreover, current black-box methods struggle to accurately localize small or out-of-distribution triggers. We propose CLIPGuard, a lightweight and fully black-box defense specifically designed to mitigate embedding-space backdoors in CLIP encoders. CLIPGuard identifies malicious regions by measuring segment-wise embedding perturbations and selectively purifies only suspicious segments via semantic inpainting, preserving benign visual content and alignment quality. Extensive experiments on STL-10, ImageNet, and diverse trigger families---including BadCLIP, BadNets, blended, patch-based, and typographic attacks---demonstrate that CLIPGuard reduces attack success rates to as low as 1.05% while maintaining clean accuracy up to 86.34%, consistently outperforming existing black-box defenses, including CleanCLIP and CleanerCLIP. Our code is available https://github.com/wsu-cyber-security-lab-ai/CLIPGuard.git
Ahmed Abdelnaby, Mohamed Elmahallawy
Washington State University, Richland, WA 99354, USA
This paper presents Text-Guided Backdoor (TGB), an adjustable backdoor attack against multimodal pretrained models that uses natural-word triggers, namely words that can naturally occur in ordinary textual inputs. Most existing backdoor attacks require specific trigger conditions that are typically not satisfied by ordinary inference inputs, thereby limiting their activation in real-world deployments. TGB overcomes this limitation by exploiting naturally occurring words as triggers, enabling stealthy activation without requiring explicit trigger insertion at inference time. This property avoids conspicuous trigger patterns and improves the practicality of TGB. Furthermore, we introduce visual adversarial perturbations on poisoned samples to modulate the model's learning of natural-word triggers, thereby enabling flexible adjustment of TGB attack strength without modifying the poisoned data. Extensive experiments are conducted on downstream tasks built upon multimodal pretrained models, including Composed Image Retrieval (CIR) and Visual Question Answering (VQA). Results demonstrate the effectiveness of TGB across diverse poisoning settings and its ability to flexibly adjust attack success rates, which reveal critical security vulnerabilities in multimodal pretrained models.
Yiyang Zhang, Chaojian Yu, Ziming Hong +4
National Anti-Counterfeit Engineering Research Center, Huazhong University of Science and Technology · School of Electronic Information and Communications, Huazhong University of Science and Technology · Sydney AI Centre, The University of Sydney