Untargeted vs Targeted Attacks
What you'll learn: How adversarial attacks differ based on whether they aim for any mistake or a specific wrong answer.
The Core Distinction
When crafting adversarial examples, attackers have two fundamentally different goals:
Untargeted attacks simply want to fool the model—any misclassification counts as success. If your model thinks a stop sign is anything but a stop sign (yield sign, speed limit, even a banana), the attacker wins.
Targeted attacks are precision strikes. The attacker doesn't just want a wrong answer—they want a specific wrong answer. They craft the perturbation so the model classifies a stop sign as exactly a "45 mph speed limit" sign, nothing else.
Why This Matters
Think of it like breaking into a building:
- Untargeted: "I just need to get inside, any door or window works."
- Targeted: "I need to enter through the executive office on the third floor."
Targeted attacks are significantly harder to execute because they must navigate the model to a precise region of decision space. The optimization problem is more constrained—you're not just crossing any decision boundary, but reaching a particular destination on the other side.
Practical Implications
Untargeted attacks are easier to generate and often transfer better between models (remember transferability from earlier lessons). They're sufficient for denial-of-service scenarios or causing general chaos.
Targeted attacks require more sophisticated perturbations but enable dangerous scenarios: making a self-driving car misclassify a pedestrian as empty road, or bypassing facial recognition by impersonating a specific person.
Key Takeaway: Untargeted attacks cause any misclassification (easier, broader threat), while targeted attacks force a specific wrong class (harder, but enables precision attacks with catastrophic consequences).