Why can adversarial attacks transfer? Explaining the transferability of evasion attacks and poisoning attacksWhy Do Adversarial Attacks Transfer? Explaining Transferability of Evasion and Poisoning Attacks
The authors uniformly model the transferability of evasion and poisoning attacks, propose three transferability metrics, and state that low-complexity surrogate models transfer better and low-complexity targets are more robust.
The attacker's goal is integrity or availability compromise; knowledge is divided into white-box (fully knows the target) and black-box (knows only the feature set X, not the training data or model type, has no query access, and trains a surrogate model on surrogate data from the same distribution); capability is divided into causative (poisoning, manipulating training data) and exploratory (evasion, manipulating test data), subject to modification constraints Φ(x).
- Why evasion and poisoning attacks constructed against one machine learning model can transfer to another unknown model had previously only been observed empirically, and the reasons were unclear. The authors aim to analyze the transferability of the two types of attacks in a unified way and identify the influencing factors.
- The authors propose a unified gradient optimization framework for evasion and poisoning, give a formal definition and upper bound of transferability, and define three metrics: the target model input gradient magnitude S, the gradient alignment R between surrogate and target, and the loss surface variance V; they also derive the poisoning gradient for logistic regression.
- On MNIST89, DREBIN, and LFW, the authors state that low-complexity target models are more robust to both types of attacks; for evasion attacks, low-complexity surrogates transfer better, while for poisoning attacks, surrogates matching the target's complexity work better; the correlation between gradient alignment and transfer rate is statistically significant by permutation test.
- The authors note that the analysis is limited to binary classification, and future directions include extending to multiclass and gray-box models; the evasion experiments did not cover poisoning of neural networks (which the authors call an open problem), and on LFW the difference in transfer rates between high- and low-complexity surrogates was not significant.
- Evaluated models
- SVMH (linear SVM with C = 100)SVML (linear SVM with C = 0.01)SVM-RBFH (SVM with RBF kernel, C = 100, γ = 0.01)SVM-RBFL (SVM with RBF kernel, C = 1, γ = 0.01)logisticH (logistic classifier with C = 10)logisticL (logistic classifier with C = 1)ridgeH (ridge classifier with α = 1)ridgeL (ridge classifier with α = 10)NNH (fully-connected neural network, weight decay = 0)NNL (fully-connected neural network, weight decay = 0.01)RFH (random forest, no depth limit)RFL (random forest, maximum depth = 8)
- Benchmarks
- MNIST89DREBINLFW
- Metrics
- test errortransfer rateevasion rateS (size of input gradients)R (gradient alignment)V (variability of loss landscape)
Researchers propose a unified optimization framework and a formal definition of transferability, explaining why evasion attacks and poisoning attacks against machine learning models can be equally effective against another, possibly unknown, model. The analysis identifies two main factors affecting attack transferability: the target model's own adversarial vulnerability, and the complexity of the substitute model used to optimize the attack, and on this basis defines three measures that affect transferability. The theoretical conclusions apply to both evasion and poisoning attacks, and are experimentally validated on a variety of linear and nonlinear classifiers and datasets.
Paper analysis
What problem does this paper attempt to solve?
Why attacks can transfer between models is still unclear; the authors analyze the transferability of evasion and poisoning attacks and its influencing factors in a unified way.
Core question: why, and when, evasion and poisoning attacks constructed against one machine learning model can transfer to another possibly unknown model had previously lacked explanation.
- Scenario and importance: Machine learning is widely deployed, but many online services do not disclose model details, so attackers can only construct attacks against a surrogate model and hope they transfer to the real model. The authors state that prior work only reported empirical phenomena of transferability, and "when and why do adversarial points transfer" was essentially unanswered.
- Shortcomings of existing methods: The authors state that the transferability of evasion attacks has several empirical studies, the transferability of poisoning integrity attacks has only recently been studied, and the transferability of poisoning availability attacks has been almost unstudied; existing work has not given a clear explanation.
- Core observation: After linearizing the loss function under attack, transferability is mainly affected by three factors—the target model's intrinsic adversarial vulnerability (input gradient magnitude), the degree of gradient alignment between the surrogate and target models, and the variance of the surrogate model's loss surface.
- Paper contributions: The authors propose a unified gradient optimization framework for evasion and poisoning, a formal definition and upper bound of transferability, three transferability metrics, derive a new poisoning availability attack against logistic regression, and conduct experiments on multiple linear and nonlinear classifiers and three datasets. The authors state that this is the first comprehensive evaluation of the transferability of evasion and poisoning availability attacks.
- Threat model (Section 2):
- Goal: integrity compromise (evading detection) or availability compromise (impairing normal function).
- Knowledge: white-box means fully knowing κ = (D, X, f, w); black-box means knowing only the feature set X, not the training data D or classifier type f, with no query access, training a surrogate model f̂ on surrogate data D̂ from the same distribution.
- Capability: causative (manipulating training and test data, i.e., poisoning) or exploratory (manipulating only test data, i.e., evasion), with modifications subject to Φ(x) (e.g., distance and box constraints).
- Victim system: binary supervised learning classifiers (the authors state this can be extended to multiclass).
What related research exists?
Related work is divided into two groups, evasion transferability and poisoning transferability; the authors state that this paper provides a unified framework and answers open questions left by prior work.
Transferability of evasion attacks
- Biggio et al. [3]—the authors state this is the earliest work to consider evasion attacks against surrogate models in a limited-knowledge scenario.
- Goodfellow et al. [14], Tramèr et al. [43], Moosavi et al. [26]—observed that different models may learn intersecting decision boundaries, in which case adversarial examples transfer better; Tramèr et al. also studied model-agnostic perturbations that depend only on training data, finding that adversarial examples constructed against linear models can transfer to higher-order models. The authors state that this paper answers some of the open questions raised by Tramèr et al.
- Liu et al. [21]—empirically observed that transferable adversarial examples correspond to gradient alignment between models; Papernot et al. [32, 33]—observed that adversarial examples transfer between models such as logistic regression, SVM, and neural networks, but the authors note that they did not give a clear explanation.
Input gradients and ensembles
- Several works [22, 35, 40, 44] propose reducing input gradient magnitude during training to defend against evasion attacks or improve accuracy; [35, 39] regard input gradient magnitude as a cause of evasion vulnerability.
- [13, 21, 43, 47] improve transferability by averaging gradients over model ensembles. The authors note that this paper achieves a similar effect with strongly regularized low-complexity surrogate models, at lower computational cost than attacking an ensemble.
Transferability of poisoning attacks
- Muñoz-González et al. [27]—a preliminary study of the transferability of poisoning availability attacks, showing that poisoning points can transfer between very simple network structures (logistic regression, MLP, Adaline).
- Suciu et al. [41]—studied the transferability of targeted poisoning attacks. The authors state that this paper is the first to study the transferability of poisoning availability attacks in depth.
Positioning: The authors state that this paper's unified optimization framework covers the evasion attacks of [3, 8, 14, 23, 42] and the poisoning attacks of [4, 18, 20, 24, 27, 48], and explains the key factors of transferability through formal definitions rather than only empirical observation.
Baselines and benchmarks: This paper does not numerically compare with other attack methods; experiments on the three datasets MNIST89, DREBIN, and LFW compare combinations of surrogate and target models of different complexity (high/low regularization).
How does the paper address this problem?
Model both types of attacks with a unified gradient optimization framework, derive a transferability upper bound by linearizing the loss, and define three metrics S, R, and V.
Overall approach: write evasion and poisoning uniformly as projected gradient ascent optimization of the attacker's objective function, then linearize the loss under attack to derive an upper bound on the effectiveness of transfer attacks, from which three computable transferability metrics are extracted.
Unified optimization framework (Section 3)
- Attacker objective: Given knowledge κ and an initial sample x, the optimal attack is x⋆ ∈ argmaxx′ ∈ Φ(x) A(x′, y, κ), i.e., maximizing the attack objective function A within the allowed modification range.
- Algorithm 1: projected gradient ascent, with step size η found by bisection line search (at most 20 iterations), and the algorithm runs at most 1,000 iterations; the authors state it usually converges in about one hundred iterations; for poisoning, attack points are optimized one by one.
- Evasion instantiation: maximize the loss
(y, x', w) = −y f(x'), subject to the distance constraint kx' − xk_p ≤ ε and box constraints; a maximum-confidence attack is used rather than minimum-distance, and the authors state that high-confidence attacks transfer better; for nonlinear classifiers, double initialization (the initial point plus the projection of a random point from another class) is used to find a better local optimum. - Poisoning instantiation: written as bilevel optimization—the outer level maximizes the loss on the unpolluted validation set, and the inner level learns a classifier on the training set with poisoning points added; the attacker can inject only a small fraction of the training set (ratio α).
Derivation of the poisoning gradient
- Hypergradient: using the chain rule and implicit differentiation through the KKT conditions, the gradient of a poisoning point is obtained (Eq. 9), capturing the implicit dependence of classifier parameters on the poisoning point.
- SVM gradient: the simplified form from [4] is reported (Eq. 10).
- Logistic regression gradient: as one of this paper's contributions, the poisoning gradient with logistic loss as the attacker's loss is derived under this framework (Eq. 11–12); the authors note that the poisoning attack of [24] maximizes a different outer objective.
Transferability definition and upper bound (Section 4)
- Formal definition: the transferability of an evasion attack is defined as the target classifier's loss at the attack point T =
(y, x + δ̂, w),线性化后 T ≈(y, x, w) + δ̂ᵀ∇_x`(y, x, w); for p = 2 a closed-form upper bound is derived: Δℓ = ε (∇x ℓ̂⊤ ∇x ℓ)/(|∇x ℓ̂|2) ≤ ε |∇x ℓ|2, i.e., the loss increase in the black-box case does not exceed that in the white-box case, with equality when the surrogate equals the target. - Metric S (input gradient magnitude): S(x, y) = k∇_x`(y, x, w)k_q, where q is the dual of the perturbation norm; the authors state that a larger input gradient of the target model may mean a larger attack impact, and that strongly regularized low-complexity models have smaller input gradients; S can only be compared within the same learning algorithm.
- Metric R (gradient alignment): the cosine similarity between the surrogate and target loss gradients; the authors state that this explains why the angle between gradients can characterize transferability, corroborating the empirical results of [21]; R is a relative comparison between surrogates, fast to compute, and requires no simulated attack.
- Metric V (loss surface variance): the variance of the loss `̂ when the surrogate training set is resampled; the authors state that large variance means unstable local optimum locations and that attacks may not transfer; V likewise can only be compared within the same learning algorithm.
- Poisoning generalization: replacing the evasion loss with the validation loss L(D, w), the same definition and three metrics apply directly.
Success determination
- Evasion uses the target model's test error on attack samples (for DREBIN, the evasion rate at 0.5% false alarm rate); poisoning uses the test error as the poisoning ratio increases; black-box transfer uses the transfer rate (the average error of the surrogate attack on the target).
What experiments did the paper conduct?
White-box and black-box transfer were measured on MNIST89, DREBIN, and LFW, and the authors state that the results confirm the roles of the three metrics S, R, and V.
Experimental setup
- Models tested: linear SVM, RBF-kernel SVM, logistic regression, ridge regression, fully connected neural network (two hidden layers), random forests, each with high-complexity (H) and low-complexity (L) hyperparameter settings (e.g., SVMH uses C = 100, SVML uses C = 0.01); poisoning experiments additionally include a CNN as a target.
- Datasets: MNIST89 (the 8 and 9 classes of MNIST, 784 dimensions); DREBIN (about 120,000 benign and about 5,000 malicious Android apps, with feature selection retaining 5,000 binary features); LFW (the 6 identities with the most images, 530 positive and 758 negative samples).
- Protocol: For evasion on MNIST89, the target is trained on 5,900 samples, the surrogate on 5,900 different samples (no queries to the target), and 1,000 test samples are used, with l2 constraint ε ∈ [0, 5], 10 repetitions; DREBIN uses 30,000 samples for training and 66,944 for testing, with l1 constraint ε ∈ {0,...,30}, injecting only features, attacking 1,000 malicious samples.
- Poisoning protocol: MNIST89 uses 500 training, 1,000 validation, and 1,000 test samples, with poisoning ratios 0%–20% (corresponding to 125 poisoning points), 10 repetitions; LFW uses 300 training, validation, and test samples per repetition.
- Metrics and statistics: test error, transfer rate, evasion rate (at 0.5% false alarm rate); two-sided binomial tests compare high- and low-complexity models (10 samples each time), and permutation tests assess the statistical significance of correlations.
- Review method: no LLM or human review; all metrics are automatic.
Main results
The paper's main results are presented as security evaluation curves and transfer matrices (Figure 5, 7, 10, 12, 14, 16, 19, 21); there are too many per-cell numbers, so the table below summarizes the statistical tests in Table 1 (p values comparing high- and low-complexity models, binomial tests on 10 samples):
Swipe horizontally to read the table
Attack Dataset (setting) White-box target p value Black-box surrogate p value Evasion MNIST89 (ε=1) <1e-2 (all algorithms) <1e-2 (all algorithms) Evasion DREBIN (ε=5 / ε=30) <1e-2 / <1e-2 <1e-2 / mostly <1e-2, 0.02 for logistic and NN Poisoning MNIST89 (5% / 20%) <1e-2 (0.02 for ridge at 5%) <1e-2 Poisoning LFW (5% / 20%) <1e-2 (0.10 for logistic at 5%, 0.21 at 20%; 0.75 for ridge at 20%) 0.75 (SVM) / 0.11 (SVM-RBF), etc., mostly not significant - The authors state that for each learning algorithm, low-complexity target models have smaller input gradients and are more robust to both evasion and poisoning (Figure 6a, 15a), and that nonlinear classifiers are overall less susceptible to attack than linear classifiers.
- The authors state that in evasion attacks, low-complexity surrogate models transfer better on average, even when using only 20% of the surrogate training data (Figure 7); in poisoning attacks, surrogates whose complexity matches the target transfer better (Figure 16).
- The authors state that on LFW the difference in transfer rate between high- and low-complexity surrogates is not significant, which the authors suggest may be due to the smaller training set.
Correlation between gradient alignment and transferability
- What was measured: the Pearson correlation ρ(δ̂, δ) between gradient alignment R and the black-box/white-box perturbations, and its relationship to the black-box/white-box error ratio (Figure 6c-d, 11c-d, 15c-d, 20c-d).
- Results: In MNIST89 evasion, the Pearson correlation between R and ρ is 0.99 and Kendall 0.93 (p < 1e-10); DREBIN evasion is 0.91 / 0.74 (p < 1e-10); MNIST89 poisoning is 0.65 / 0.35 (p < 1e-8 / < 1e-4); LFW poisoning is 0.45 / 0.27 (p < 1e-3 / < 1e-2). The correlation between R and the error ratio is weaker (e.g., MNIST89 poisoning Pearson 0.31, p = 0.01).
- Authors' interpretation: The authors state that gradient alignment is an accurate measure of transferability, but only a relative metric; transferability also depends on the target model's input gradient magnitude.
Loss surface variance V and the exceptions of random forests and neural networks
- Role of V: In evasion, larger V means worse surrogate transfer (Figure 6b, 11b); in poisoning, increasing V for SVM surrogates is instead beneficial (Figure 15b), and the authors state that in poisoning, reducing V is less important than gradient alignment.
- Random forests: In MNIST89 evasion, small perturbations suffice to attack random forests (the last two columns of Figure 7); after inspecting the trees, the authors found this is caused by split thresholds close to extreme data values; under l1 attacks on DREBIN, random forests are much more robust, which the authors attribute to l1 changing only a few features. Random forests are also fairly robust to poisoning.
- Neural networks: NNs are relatively robust when poisoned by low-complexity linear surrogates, which the authors suggest may be because their large capacity can fit outliers; the authors state that poisoning availability attacks against NNs remain an open problem.
Other ablations and analyses
- Surrogate training data size: In MNIST89 evasion, transfer error with 20% and 100% surrogate data is similar (the top and bottom rows of Figure 7).
- Exceptions where black-box outperforms white-box: In poisoning, some black-box/white-box error ratios exceed 1 (Figure 15d), and the authors state that optimizing against a smoother surrogate may find a better local optimum of the objective function.
- Perturbation magnitude: Low-complexity models require larger perturbations to be successfully attacked (the ε annotations in Figure 9, 18, 23, e.g., SVML requires ε = 1.7, SVMH only ε = 0.45).
- DREBIN feature selection: Retaining 5,000 features reduces the detection rate at 0.5% false alarm rate by only 2% on average.
What are some points that can be further explored?
The authors state it can be extended to multiclass and gray-box models; the experiments cover three datasets and seven types of classifiers, with some combinations not covered.
Limitations and future directions noted by the authors
- Multiclass extension (Section 7): the authors state that future work includes extending the analysis to the multiclass setting (Section 2 also notes that the threat model and attacks are designed for binary classification).
- Gray-box models (Section 7): the authors state that future work could consider gray-box models where the attacker has additional system knowledge (e.g., [41]).
- Application-relevant scenarios (Section 7): the authors state that application scenarios such as network security may impose additional constraints on the threat model and attack scenario, and affect transferability in interesting ways.
- NN poisoning unresolved (Section 5.2.1): the authors state that due to the complexity of bilevel optimization and the non-convexity of the inner learning problem, designing efficient poisoning availability attacks against neural networks remains an open problem.
- Bias-variance tradeoff (Section 5.3): the authors suggest that when defenders choose low-complexity models, they need to consider the bias-variance tradeoff and still perform relatively well on the original task.
Scope of experiments
- The models tested are six types—linear SVM, RBF-kernel SVM, logistic, ridge, fully connected NN, random forests (each with high and low complexity settings)—and the poisoning experiments additionally target a CNN; 7 classifier types in total (Section 5).
- The datasets are MNIST89, DREBIN (evasion only), and LFW (poisoning only); the poisoning experiments do not include DREBIN, and the evasion experiments do not include LFW (Section 5.1, 5.2).
- White-box poisoning covers only SVM, logistic, and ridge; NN and CNN appear only as poisoning targets, and random forests are not poisoned with gradient methods (Section 5.2.1).
- Evasion attacks are maximum-confidence l2 (MNIST89) and l1 (DREBIN) attacks; the black-box setting is no queries, with surrogate data different from but from the same distribution as the target training data (Section 5.1.1).
- The paper does not report attack runtime or computational cost figures; the number of repetitions is 10 (Section 5.1.1, 5.2.1).
Summarize the main content of the paper
A unified framework plus three metrics explain attack transferability: target complexity, gradient alignment, and loss surface variance.
A paper analyzing the transferability of adversarial attacks (USENIX Security 2019 preprint) that studies why evasion and poisoning availability attacks can transfer between models.
- Problem: Attackers can often only construct attacks against a surrogate model, and transferability had previously only been observed empirically, lacking explanation; the transferability of poisoning availability attacks has been almost unstudied.
- Method: The authors propose a unified gradient-ascent optimization framework for evasion and poisoning, give a formal definition of transferability and a linearized upper bound, and define three metrics—the target input gradient magnitude S, the gradient alignment R between surrogate and target, and the surrogate loss surface variance V; they also derive the poisoning gradient for logistic regression.
- Result one: On MNIST89, DREBIN, and LFW, low-complexity (strongly regularized) target models are more robust to both types of attacks, with most statistical tests p < 1e-2 (Table 1).
- Result two: For evasion attacks, low-complexity surrogates transfer better, even when using only 20% of the surrogate training data; for poisoning attacks, surrogates whose complexity matches the target transfer better.
- Result three: The Pearson correlation coefficient between gradient alignment R and the black-box/white-box perturbation correlation is 0.99 on MNIST89 evasion and 0.91 on DREBIN evasion (p < 1e-10); the authors state that R is an accurate relative measure of transferability.
- Exceptions: Random forests are easily attacked by small perturbations under l2 evasion on MNIST89, but are robust under l1 attacks on DREBIN; NNs are relatively robust when poisoned by low-complexity linear surrogates; on LFW, surrogate complexity has no significant effect on transfer rate.
- Authors' conclusion: For black-box evasion, attackers should choose low-complexity surrogates; for poisoning, they should estimate the target's regularization level and match it; defenders can improve robustness to both types of attacks by regularizing to reduce input gradients, but must trade off bias-variance.
Related papers
- The Space of Transferable Adversarial ExamplesAnalysis / interpretabilityarXiv
Show 1 more papers
- Face-Off: Adversarial Face ObfuscationDefensesarXiv