Glossary
Adversarial attack
Written with AI from the sources below and checked against our facts sheet. Last checked . How this site is made · Spot an error?
Part of: EU AI Act
An adversarial attack is a deliberate attempt to make an AI system fail, misbehave or leak information. It exploits how the system learns or processes inputs. The main types include evasion with crafted inputs, data poisoning, prompt injection, model extraction and membership inference. Many need nothing more than ordinary query access to the system.
In plain English
A forger studies a bank's note scanner and learns exactly which tiny details it checks. Then they print notes that pass the scanner but would never fool a careful cashier. Adversarial attacks exploit AI the same way. They target the patterns a model relies on, which are often not the ones a person would use.
The main types:
| Attack | When it strikes | What the attacker does |
|---|---|---|
| Evasion | Run time | Alters inputs slightly so the model misclassifies them |
| Data poisoning | Training | Corrupts training data so the model learns bad behavior |
| Prompt injection | Run time | Hides instructions in input that override the model's own |
| Model extraction | Run time | Queries the model repeatedly to build a copy |
| Membership inference | Run time | Probes outputs to learn whether someone's data was in the training set |
The research field is called adversarial machine learning. NIST catalogs these attacks and their mitigations in a taxonomy (AI 100-2 E2025).
Example
Gullwing Insurance, a fictional insurer, uses a vision model to estimate car damage from customer photos. Its fraud team notices odd claims: photos of minor scratches valued as major damage.
Investigators find a fraud ring adding a faint, almost invisible pattern to photos. People see a small scratch, but the model sees severe damage. This is an evasion attack. The ring had tested patterns through Gullwing's own claims app until one worked.
Gullwing responds in layers:
- adversarial training, adding altered examples so the model learns to resist them;
- input checks that flag edited or re-compressed images;
- human review for any estimate above a set amount or with low confidence;
- rate limits and monitoring for repeated submissions from one device.
It also adds evasion scenarios to its next red team exercise.
Why it matters
- EU AI Act. High-risk systems must be resilient against attempts by unauthorized third parties to alter their use, outputs or performance by exploiting vulnerabilities (Art. 15(5)). Technical measures must address, where appropriate, data poisoning, model poisoning, "adversarial examples or model evasion," confidentiality attacks and model flaws.
- NIST. The AI RMF names adversarial examples, data poisoning, and exfiltration of models or training data as common security concerns. MEASURE 2.7 expects security and resilience to be evaluated and documented.
- Real-world proof. Researchers showed that black and white stickers on a real stop sign could make a vision model misclassify it (Eykholt et al.).
- Catalogs. MITRE ATLAS and the OWASP Top 10 for LLM Applications list attacker techniques to test against. Both are voluntary.
How the AIGP exam tests it
Lesson III.C.6 covers the main attacks and how red teams find them.
- The tell: timing. Training-time corruption is data poisoning. A crafted input to a finished model is evasion. Instructions hidden in content the model reads are indirect prompt injection.
- The tell: access. Evasion, model extraction and membership inference need only query access. Poisoning needs a route into the training data.
- Privacy harm without theft. Membership inference can reveal sensitive facts, such as presence in a medical dataset, without stealing any data.
- Trap: catalogs as law. OWASP, MITRE ATLAS and NIST guidance are voluntary. An option calling them legally binding is wrong.
Frequently asked questions
What is an adversarial example?
An adversarial example is an input deliberately altered, often in ways people barely notice, so a model gets it wrong. A few changed pixels or stickers can make an image classifier misread a road sign. Adversarial examples power evasion attacks, and the EU AI Act names them among the vulnerabilities high-risk systems must address.
What are the main types of adversarial attacks?
Evasion uses crafted inputs to fool a finished model. Data poisoning corrupts training data. Prompt injection hides instructions that override a model's own. Model extraction copies a model through its outputs. Membership inference reveals whether someone's data was used in training. NIST's taxonomy organizes attacks by attacker goals, capabilities and knowledge, and by life cycle stage.
How do you defend against adversarial attacks?
In layers. Threat model the system, then red team it. Harden the model with adversarial training and input validation. Limit query rates and what the model can reach. Protect the training pipeline with provenance, lineage and access control. Keep humans reviewing high-stakes outputs, and monitor for unusual patterns. No single defense is complete.
What is the difference between an adversarial attack and red teaming?
An adversarial attack is what a real attacker does to make an AI system fail. Red teaming is an authorized exercise in which defenders simulate those attacks to find weaknesses first. Red teams use adversarial techniques, but with permission, a defined scope and the goal of fixing what they find.
Related
Sources
- NIST AI 100-2 E2025, Adversarial Machine Learning: A Taxonomy and Terminology of Attacks and Mitigations (March 2025)
- EU AI Act Service Desk, Article 15: Accuracy, robustness and cybersecurity
- Regulation (EU) 2024/1689 (EU AI Act), Art. 15(5), EUR-Lex
- NIST AI 100-1, AI Risk Management Framework 1.0, section 3.3 and MEASURE 2.7
- Eykholt et al., Robust Physical-World Attacks on Deep Learning Visual Classification (2018)
- MITRE ATLAS
- OWASP Top 10 for LLM Applications (2025)