Boosting Adversarial Transferability with Spatial Adversarial Alignment
Abstract
Adversarial attacks often suffer from poor transferability when the surrogate and target models belong to different architectural families, such as Convolutional Neural Networks (CNNs) and Vision Transformers (ViTs). This paper proposes Spatial Adversarial Alignment (SAA), a novel framework that fine-tunes a surrogate model to mimic both the spatial feature distributions and adversarial responses of a "witness" model. By aligning local and global features across clean and adversarial inputs, SAA significantly enhances cross-architecture attack success rates, effectively bridging the gap between disparate neural network designs.
Introduction
Generating adversarial examples that can fool black-box models is a critical challenge in AI security. While transferability is relatively high between similar architectures, it drops sharply when attacking a ViT using a CNN surrogate, or vice versa. This is primarily due to the fundamental differences in how these models process visual information: CNNs rely on local convolutions, whereas ViTs utilize global self-attention. Existing alignment methods often focus solely on final output predictions, failing to capture the structural nuances that drive model decisions.
Methodology
The core of the proposed approach is Spatial Adversarial Alignment (SAA). Unlike previous methods that only align final output logits, SAA performs a deeper synchronization between a surrogate model and a secondary "witness" model.
As shown in Figure 1, SAA consists of two primary mechanisms:
- Spatial-aware Alignment: This component aligns the local feature maps of the surrogate with the patch-based representations of the witness model. By supervising local regions, the surrogate learns to distribute its attention in a manner consistent with the witness architecture.
- Adversarial-aware Alignment: To capture shared vulnerabilities, SAA iteratively generates adversarial examples during the fine-tuning phase. It forces the surrogate to align its internal representations of these perturbed images with those of the witness model, creating a "shared language" of adversarial features.
Experimental Results
The effectiveness of SAA was evaluated on an ImageNet-compatible dataset across a wide range of target models, including various CNNs (ResNet, VGG, DenseNet) and ViTs (Swin, PVT, MobViT).
Key findings include:
- Significant Performance Boost: SAA consistently improves the Attack Success Rate (ASR) of existing transfer attacks. As detailed in Figure 5, adding SAA to baseline methods like MI, NI, or SSA leads to substantial gains, often exceeding 20% in average ASR.
- Cross-Architecture Transferability: When using a ResNet-50 surrogate to attack ViT targets, SAA achieved improvements of up to 39.1% over state-of-the-art alignment baselines. The authors found that asymmetric pairing (e.g., a CNN surrogate with a ViT witness) yields the best results.
- Synergy with Advanced Attacks: SAA acts as a powerful multiplier. When integrated with the SSA-DI-TI-MI ensemble attack, it reached an average ASR of 88.2% across ten diverse black-box models, nearly closing the gap with white-box performance levels.
Conclusion
Spatial Adversarial Alignment (SAA) provides a robust solution to the architectural mismatch problem in adversarial transferability. By forcing a surrogate model to adopt the spatial and adversarial characteristics of a different architecture, SAA enables the generation of more universally effective adversarial examples. While the fine-tuning process adds computational overhead (approximately 10 hours on an RTX 3090), the resulting gains in black-box attack success rates represent a significant step forward in understanding and exploiting cross-model vulnerabilities.
Summary updated