FoCLIP: A Feature-Space Misalignment Framework for CLIP-Based Image Manipulation and Detection
Yulin Chen, Zeyuan Wang, Tianyuan Yu, Yingmei Wei, Liang Bai
TL;DR
FoCLIP addresses the vulnerability of CLIP-based metrics to cross-modal misalignment by proposing a tripartite, gradient-based optimization framework that aligns image features with multiple target prompts while preserving visual fidelity. It introduces Feature Alignment Loss, Distribution Balance Loss, and Pixel-Guard Regularization Loss, and demonstrates substantial CLIPscore improvements across artistic prompts and ImageNet subsets. A grayscale sensitivity phenomenon is leveraged to develop a 91% accurate tampering detector, providing a practical defense against CLIP-based spoofing. Overall, the work highlights security risks in CLIP-based multimodal systems and offers both an effective attack framework and a complementary tampering-detection mechanism.
Abstract
The well-aligned attribute of CLIP-based models enables its effective application like CLIPscore as a widely adopted image quality assessment metric. However, such a CLIP-based metric is vulnerable for its delicate multimodal alignment. In this work, we propose \textbf{FoCLIP}, a feature-space misalignment framework for fooling CLIP-based image quality metric. Based on the stochastic gradient descent technique, FoCLIP integrates three key components to construct fooling examples: feature alignment as the core module to reduce image-text modality gaps, the score distribution balance module and pixel-guard regularization, which collectively optimize multimodal output equilibrium between CLIPscore performance and image quality. Such a design can be engineered to maximize the CLIPscore predictions across diverse input prompts, despite exhibiting either visual unrecognizability or semantic incongruence with the corresponding adversarial prompts from human perceptual perspectives. Experiments on ten artistic masterpiece prompts and ImageNet subsets demonstrate that optimized images can achieve significant improvement in CLIPscore while preserving high visual fidelity. In addition, we found that grayscale conversion induces significant feature degradation in fooling images, exhibiting noticeable CLIPscore reduction while preserving statistical consistency with original images. Inspired by this phenomenon, we propose a color channel sensitivity-driven tampering detection mechanism that achieves 91% accuracy on standard benchmarks. In conclusion, this work establishes a practical pathway for feature misalignment in CLIP-based multimodal systems and the corresponding defense method.
