Abstract
This paper introduces Adversary Preferences Alignment (APA), a novel framework for generating unrestricted adversarial examples (UAE) using diffusion models. By reframing adversarial generation as a preference alignment problem, the authors decouple the conflicting objectives of visual consistency and attack effectiveness. Through a two-stage process involving LoRA fine-tuning and dual-path guidance with diffusion augmentation, APA achieves state-of-the-art transferability and visual quality, significantly outperforming existing diffusion-based attacks.
Introduction
Traditional adversarial attacks typically rely on adding imperceptible $L_p$ perturbations to images. However, these are increasingly vulnerable to modern defensive techniques. Unrestricted adversarial attacks (UAE) offer a more robust alternative by modifying semantic features, colors, or textures. While diffusion models are powerful tools for generating such naturalistic variations, controlling their latent space to satisfy both visual similarity and attack success is challenging.
As illustrated in Figure 1, standard preference alignment (like RLHF) focuses on human-centric goals like text-to-image alignment. In contrast, an adversary seeks to balance two often conflicting preferences: Attack Effectiveness and Visual Consistency. Simultaneous optimization of these goals often leads to "reward hacking," where the model sacrifices image quality to maximize attack success. APA addresses this by explicitly decoupling these objectives into a sequential alignment framework.
Methodology: Adversary Preferences Alignment (APA)
The APA framework operates in two distinct stages to prevent objective interference and ensure high-quality adversarial generation.
Stage 1: Visual Consistency Alignment (VCA)
To anchor the generation within the manifold of the original image, the framework first fine-tunes the diffusion model's Low-Rank Adaptation (LoRA) parameters. This stage uses a differentiable visual similarity reward ($R_s$) to ensure the model maintains the structural and semantic integrity of the clean image before any adversarial optimization occurs.
Stage 2: Attack Effectiveness Alignment (AEA)
Once visual consistency is secured, the framework optimizes for attack success. APA introduces two key innovations to enhance transferability to black-box models:
- Dual-path Attack Guidance: Optimization gradients are calculated at both the final trajectory level and the intermediate step level. This ensures the denoising process remains aligned with the adversarial goal throughout the generation.
- Diffusion Augmentation: To prevent overfitting to the white-box substitute classifier, APA utilizes intermediate, partially-denoised images as augmented training data. This acts as a regularizer, improving the attack's ability to fool unseen target architectures.
Experimental Evaluation
The method was evaluated using the ImageNet-compatible Dataset (1,000 images). Attacks were generated using a ResNet-50 substitute model and tested against a diverse suite of 10 target models, including CNNs (e.g., EfficientNet, Inception) and Vision Transformers (e.g., ViT, Swin). The robustness of the attacks was further challenged by various defenses, including adversarial training and preprocessing techniques like JPEG compression and DiffPure.
Results and Discussion
APA demonstrates a significant leap in performance over previous state-of-the-art methods. The gradient-checkpointing variant (APA-GC) achieved an average black-box Attack Success Rate (ASR) of 88.02%, a substantial improvement over the previous leading diffusion attack, ACA, which reached only 59.49%.
Even against robustly defended models, APA-GC maintained a high average ASR of 70.20%. Crucially, this effectiveness does not come at the cost of image quality; the framework maintained excellent visual metrics, including an LPIPS of 0.23 and an SSIM of 0.69. Qualitative analysis shows that APA introduces naturalistic changes to textures and backgrounds rather than obvious pixel-level artifacts.
Limitations
The authors identify a trade-off between computational cost and quality. Increasing the number of guidance steps ($T_a$) improves ASR but increases inference time and can eventually lead to quality degradation due to biased gradient chains. Additionally, the high-performance APA-GC variant requires more computation than simpler skip-gradient approximations.
Conclusion
By framing adversarial generation as a preference alignment problem, APA provides a robust and theoretically grounded method for creating unrestricted adversarial examples. The decoupling of visual and adversarial goals effectively mitigates reward hacking, while diffusion augmentation ensures high transferability. This research suggests that alignment techniques used for AI safety can be effectively repurposed to understand and enhance model vulnerabilities.
Summary updated