RAID: A Dataset for Testing the Adversarial Robustness of AI-Generated Image Detectors

Hicham Eddoubi, Jonas Ricker, Federico Cocchi, Lorenzo Baraldi, Angelo Sotgiu, Maura Pintor, Marcella Cornia, Asja Fischer, Rita Cucchiara, Battista BiggioarXiv 2025 · DOI

Abstract

As text-to-image (T2I) models achieve unprecedented levels of realism, the demand for reliable AI-generated image detectors has surged. However, current detectors are often evaluated under idealized conditions that ignore the threat of intentional evasion. This paper introduces RAID (Robust evaluation of AI-generated image Detectors), a comprehensive dataset of 72,000 adversarial images. By employing ensemble-based iterative attacks, we demonstrate that state-of-the-art detectors—including commercial solutions—are highly susceptible to invisible pixel-level perturbations. RAID serves as a critical benchmark for developing the next generation of robust synthetic media forensics.

Introduction

The rapid advancement of models like Stable Diffusion and Midjourney has made synthetic imagery nearly indistinguishable from reality. In response, the research community has developed numerous "deepfake detectors" that report near-perfect accuracy on standard benchmarks. Yet, these metrics often mask a fundamental vulnerability: adversarial robustness. A malicious actor can easily manipulate a fake image to bypass detection systems, creating a significant security blind spot.

The Problem of Adversarial Robustness

Adversarial attacks involve adding a minute amount of "noise" to an image—perturbations so subtle they are imperceptible to the human eye but mathematically optimized to mislead machine learning models. As shown in Figure 1, an image initially identified as "Fake" with 70% confidence can be transformed into one classified as "Real" with 91% confidence through the addition of targeted adversarial noise.

An adversarial attack flips a detector's prediction from "Fake" to "Real" using invisible noise.

The RAID Dataset and Methodology

To systematically study this phenomenon, we developed the RAID dataset using an Ensemble Attack pipeline.

Ensemble Optimization

Rather than targeting a single model, we optimized perturbations against an ensemble of seven state-of-the-art detectors (including ResNet, CLIP, and ConvNext architectures). We utilized Projected Gradient Descent (PGD) to find pixel changes that maximize detector error while remaining within a strict "perturbation budget" ($\epsilon$). This approach ensures that the resulting attacks are highly transferable to unseen or black-box models.

Dataset Composition

RAID consists of 96,000 images in total:

  • 24,000 original images (both real and synthetic) sourced from the $D^3$ dataset.
  • 72,000 adversarial examples generated across three noise levels ($\epsilon = 8/255, 16/255, 32/255$).
  • Base images were generated using four diverse models: Stable Diffusion (v1.4, v2.1, XL) and DeepFloyd IF.

Experimental Results

Our evaluation reveals a "robustness illusion" in current detection technology.

  • Total Failure in White-Box Scenarios: When an attacker has access to the detector's parameters, F1-scores for almost all tested models plummeted to 0.0.
  • Devastating Transferability: Even in black-box settings where the specific model is unknown, RAID's ensemble attacks proved highly effective. For instance, the Corvi et al. detector saw its AUROC drop from 0.99 to 0.67.
  • Commercial Vulnerability: Commercial-grade APIs are not immune. Sightengine's detection accuracy on AI-generated images fell from 0.66 to 0.0 when faced with RAID-protected images.

Discussion and Future Work

While RAID provides a robust benchmarking tool, it has limitations. Adversarial perturbations were constrained to the center region of images due to varying input requirements across detector architectures. Furthermore, as generative AI continues to evolve, the RAID dataset will require continuous updates to remain relevant.

The ultimate goal of this research is to move beyond breaking detectors toward building more resilient ones. The most promising path forward is adversarial training, where detectors are re-trained using adversarial examples to improve their inherent robustness.

The proposed re-training pipeline incorporates adversarial data to harden detectors against evasion attempts.

By providing a standardized, large-scale dataset, RAID enables the community to transition from laboratory-perfect detectors to real-world-ready security tools.

Summary updated

BibTeX
@misc{eddoubi2025raid,
  author = {Hicham Eddoubi and Jonas Ricker and Federico Cocchi and Lorenzo Baraldi and Angelo Sotgiu and Maura Pintor and Marcella Cornia and Lorenzo Baraldi and Asja Fischer and Rita Cucchiara and Battista Biggio},
  title = {{RAID: A Dataset for Testing the Adversarial Robustness of AI-Generated Image Detectors}},
  year = {2025},
  eprint = {2506.03988},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2506.03988},
}
Figure