DiffAttack: Evasion Attacks Against Diffusion-Based Adversarial Purification
Mintong Kang, Dawn Song, Bo Li
TL;DR
This paper addresses the vulnerability of diffusion-based adversarial purification defenses, which use DDPMs or score-based models to cleanse inputs, by introducing DiffAttack. DiffAttack combines a deviated-reconstruction loss to induce inaccurate density-gradient estimates with a segment-wise forwarding-backwarding algorithm to enable memory-efficient backpropagation through the long diffusion paths. Empirically, it substantially reduces robust accuracy on CIFAR-10 and ImageNet compared with state-of-the-art attacks across both purification paradigms, and it demonstrates constant-memory scaling with diffusion length. The work provides insights into the robustness of diffusion purification and motivates developing more robust sampling and defense mechanisms that address gradient reliability and memory constraints in adversarial settings.
Abstract
Diffusion-based purification defenses leverage diffusion models to remove crafted perturbations of adversarial examples and achieve state-of-the-art robustness. Recent studies show that even advanced attacks cannot break such defenses effectively, since the purification process induces an extremely deep computational graph which poses the potential problem of gradient obfuscation, high memory cost, and unbounded randomness. In this paper, we propose a unified framework DiffAttack to perform effective and efficient attacks against diffusion-based purification defenses, including both DDPM and score-based approaches. In particular, we propose a deviated-reconstruction loss at intermediate diffusion steps to induce inaccurate density gradient estimation to tackle the problem of vanishing/exploding gradients. We also provide a segment-wise forwarding-backwarding algorithm, which leads to memory-efficient gradient backpropagation. We validate the attack effectiveness of DiffAttack compared with existing adaptive attacks on CIFAR-10 and ImageNet. We show that DiffAttack decreases the robust accuracy of models compared with SOTA attacks by over 20% on CIFAR-10 under $\ell_\infty$ attack $(ε=8/255)$, and over 10% on ImageNet under $\ell_\infty$ attack $(ε=4/255)$. We conduct a series of ablations studies, and we find 1) DiffAttack with the deviated-reconstruction loss added over uniformly sampled time steps is more effective than that added over only initial/final steps, and 2) diffusion-based purification with a moderate diffusion length is more robust under DiffAttack.
