Abstract: Rapid progress is being made in developing large, pretrained, task-agnostic foundational vision models such as CLIP, ALIGN, DINOv2, etc. In fact, we are approaching the point where these models do not have to be finetuned downstream, and can simply be used in zero-shot or with a lightweight probing head. Critically, given the complexity of working at this scale, there is a bottleneck where relatively few organizations in the world are executing the training then sharing the models on centralized platforms such as HuggingFace and torch.hub. The goal of this work is to identify several key adversarial vulnerabilities of these models in an effort to make future designs more robust. Intuitively, our attacks manipulate deep feature representations to fool an out-of-distribution (OOD) detector which will be required when using these open-world-aware models to solve closed-set downstream tasks. Our methods reliably make in-distribution (ID) images (w.r.t. a downstream task) be predicted as OOD and vice versa while existing in extremely low-knowledge-assumption threat models. We show our attacks to be potent in whitebox and blackbox settings, as well as when transferred across foundational model types (e.g., attack DINOv2 with CLIP)! This work is only just the beginning of a long journey towards adversarially robust foundational vision models.
Introduction
The landscape of computer vision is shifting from task-specific training to the deployment of massive, pre-trained foundational models like CLIP, DINOv2, and ALIGN. These models are often used off-the-shelf in zero-shot settings, leveraging their broad feature representations to classify unseen objects. However, this paradigm introduces a significant security bottleneck. Because training these models requires immense computational resources, a few centralized hubs host the majority of models used globally. This "architectural monoculture" allows adversaries to easily predict the model a system might be using, opening the door for targeted adversarial exploits.
Methodology: Manipulating the Feature Space
Unlike traditional adversarial attacks that target the final classification layer, this research focuses on attacks that manipulate the model's internal feature space. This approach is particularly effective against systems using Out-of-Distribution (OOD) detectors to filter unsafe or irrelevant inputs.
The researchers introduce two primary strategies:
- ID → OOD (Away From Start - AFS): This attack perturbs a valid In-Distribution (ID) image to move its feature representation as far as possible from its original location. The goal is to trigger the OOD detector, causing it to reject valid inputs as "garbage" (a silent false negative).
- OOD → ID (Towards Target + Away From Start): This "distal" attack starts with random noise and perturbs it until the model's feature space identifies it as a high-confidence match for a specific ID class (e.g., "Dogs"). This tricks the system into accepting noise as a valid object (a silent false positive).
Experimental Setup
The attacks were evaluated across multiple downstream tasks (OxfordPets, Food101, ImageNet-20/100) and OOD benchmarks (iNaturalist, Places, SUN, Textures). The model pool included eight popular architectures from HuggingFace, spanning different training algorithms (contrastive learning vs. self-distillation) and backbones (Vision Transformers and ConvNeXT).
Key Results and Transferability
The attacks demonstrated devastating potency. In whitebox settings, the ID → OOD attack achieved nearly 100% False Negative Rates (FNR95). Even more concerning is the cross-algorithm transferability: perturbations designed for CLIP (image-text contrastive) were found to be effective against DINOv2 (self-distillation). This suggests that different foundational training methods are converging on similar feature alignments, creating a universal vulnerability.
Blackbox ensemble attacks also proved highly effective, particularly when combining different model types. The OOD → ID "distal" attacks were remarkably successful, with random noise being predicted as target classes with high confidence across various architectures and head types, whether using zero-shot approaches, linear probes, or k-Nearest Neighbor (kNN) classifiers.
Conclusion and Future Outlook
This work highlights a critical weakness in the current "no fine-tuning" workflow of foundational models. The static nature of the feature extractor provides a fixed target for attackers. While the researchers used standard ℓ∞ constraints, future work may explore semantically similar perturbations or attacks on localization-based models like Segment-Anything. Ultimately, this study serves as a "call to arms" for the AI community to prioritize adversarial robustness during the large-scale pre-training of foundational models.
Summary updated