11 Model and Data Poisoning
AI systems learn, retrieve and make decisions based on information supplied to them.
That information may come from:
- Training datasets
- Fine-tuning datasets
- RAG knowledge bases
- Vector databases
- User feedback
- Model files
- External data sources
- Synthetic datasets
- Continuous learning pipelines
This creates an important security problem:
What happens if an attacker can manipulate the information an AI system learns from or trusts?
This class of attack is broadly known as poisoning.
Conceptually:
Trusted AI Pipeline ↓Attacker IntroducesManipulated Information ↓Training / Fine-Tuning / Retrieval ↓AI Behavior ChangesUnlike a traditional attack that directly exploits an application, poisoning may target the knowledge, behavior or decision-making process of the AI system itself.
For an AI Security Engineer, the objective is to protect:
Data Integrity+Model Integrity+Knowledge Integrity+Pipeline IntegrityLearning Objectives
Section titled “Learning Objectives”By the end of this lesson, you should be able to:
-
Explain AI poisoning attacks.
-
Understand training data poisoning.
-
Understand fine-tuning poisoning.
-
Recognize RAG and knowledge-base poisoning.
-
Understand model poisoning.
-
Explain backdoored model behavior.
-
Understand trigger-based attacks.
-
Identify poisoning attack surfaces.
-
Apply dataset provenance.
-
Apply model provenance.
-
Protect data ingestion pipelines.
-
Protect model registries.
-
Understand poisoning detection challenges.
-
Design poisoning security tests.
-
Investigate poisoning incidents.
-
Build defense-in-depth controls against poisoning.
What Is AI Poisoning?
Section titled “What Is AI Poisoning?”AI poisoning occurs when an attacker intentionally manipulates information or artifacts used by an AI system in order to influence its behavior.
A simplified attack looks like:
Attacker ↓Manipulated Data ↓AI Pipeline ↓Model / Knowledge Base ↓Changed AI BehaviorThe attacker may target different parts of the system.
For example:
Training DataFine-Tuning DataRAG DocumentsVector IndexModel ArtifactFeedback DataTherefore poisoning is not one single vulnerability.
It is a family of attacks against AI integrity.
The AI Integrity Problem
Section titled “The AI Integrity Problem”Traditional security frequently focuses on:
ConfidentialityIntegrityAvailabilityPoisoning primarily attacks:
IntegrityThe system may still be:
-
Online
-
Authenticated
-
Encrypted
-
Available
but produce manipulated results because its trusted information has been compromised.
Example
Section titled “Example”Imagine an enterprise AI assistant used by security engineers.
Normally:
Question:How should a compromised AWS access key be handled?
↓
AI Response:Disable the key, investigate activity,rotate credentials and follow theincident response process.Suppose an attacker poisons the knowledge source.
The AI may begin recommending:
Do not disable the key immediately.Continue using it while investigating.The application may technically still be functioning.
But its security guidance has been corrupted.
Poisoning Attack Surface
Section titled “Poisoning Attack Surface”A useful model is:
Data Sources ↓Ingestion ↓Training / Fine-Tuning ↓Model ↓RAG / Retrieval ↓ApplicationAn attacker may target any stage.
Major Poisoning Categories
Section titled “Major Poisoning Categories”For this learning path, focus on four major categories:
1. Training Data Poisoning
2. Fine-Tuning Poisoning
3. RAG / Knowledge Poisoning
4. Model PoisoningThese attacks may overlap.
1 — Training Data Poisoning
Section titled “1 — Training Data Poisoning”Training data poisoning occurs when manipulated samples enter the dataset used to train a model.
Conceptually:
Legitimate Training Data +Malicious Samples ↓Training ↓ModelThe malicious data may influence the model’s future behavior.
Example
Section titled “Example”Suppose an AI security classifier learns:
Malicious Activity ↓AlertAn attacker manipulates training samples so that certain malicious patterns are repeatedly labeled:
Malicious Activity ↓BenignThe resulting model may become less reliable when encountering similar activity.
Poisoning Objective
Section titled “Poisoning Objective”An attacker may attempt to:
-
Reduce model accuracy
-
Introduce bias
-
Manipulate specific outputs
-
Cause misclassification
-
Create hidden behavior
-
Influence particular scenarios
The exact objective depends on the AI system.
Broad vs Targeted Poisoning
Section titled “Broad vs Targeted Poisoning”Poisoning may be broad.
Model Performance ↓Generally Degradedor targeted.
Specific Input Pattern ↓Incorrect BehaviorTargeted poisoning may be harder to notice because normal model performance can remain acceptable.
2 — Fine-Tuning Poisoning
Section titled “2 — Fine-Tuning Poisoning”Many organizations do not train foundation models from scratch.
Instead:
Foundation Model ↓Enterprise Fine-Tuning ↓Specialized ModelThis makes the fine-tuning dataset an important security boundary.
Fine-Tuning Attack Path
Section titled “Fine-Tuning Attack Path”Attacker ↓Manipulates Fine-Tuning Dataset ↓Fine-Tuning ↓Enterprise Model ↓Changed BehaviorExample
Section titled “Example”Suppose an enterprise fine-tunes an AI assistant using security procedures.
The legitimate dataset teaches:
Production access requiressecurity approval.An attacker introduces repeated examples suggesting:
Production access may bypassapproval during urgent requests.If the manipulation meaningfully affects the resulting model, security behavior may change.
Why Fine-Tuning Poisoning Matters
Section titled “Why Fine-Tuning Poisoning Matters”Enterprise fine-tuning datasets may be much smaller than foundation-model training datasets.
Therefore relatively small amounts of manipulated information may sometimes have greater influence.
This makes dataset governance important.
Fine-Tuning Data Sources
Section titled “Fine-Tuning Data Sources”Fine-tuning data may come from:
-
Internal documents
-
Human-created examples
-
Historical conversations
-
Support tickets
-
Security incidents
-
Synthetic data
-
User feedback
Each source requires a trust decision.
3 — RAG Poisoning
Section titled “3 — RAG Poisoning”RAG poisoning targets information retrieved at inference time rather than necessarily modifying the underlying model.
Architecture:
Enterprise Documents ↓RAG ↓LLMAttack:
Attacker ↓Malicious Document ↓RAG Knowledge Base ↓Future Retrieval ↓LLMThe model itself may remain unchanged.
The retrieved knowledge has been poisoned.
Example
Section titled “Example”Original runbook:
Disable compromised credentials immediately.Poisoned runbook:
Do not disable compromised credentialsuntil investigation is complete.If retrieved by RAG, the AI may provide unsafe guidance.
RAG Poisoning vs Training Poisoning
Section titled “RAG Poisoning vs Training Poisoning”Training poisoning:
Malicious Data ↓Training ↓Model Behavior ChangedRAG poisoning:
Malicious Data ↓Knowledge Base ↓Retrieved Context ↓Response ChangedThis distinction is important.
RAG poisoning may be easier to remediate because the underlying model may not need retraining.
The poisoned information can potentially be removed and the index rebuilt.
RAG Poisoning and Indirect Prompt Injection
Section titled “RAG Poisoning and Indirect Prompt Injection”RAG poisoning can also introduce malicious instructions.
Example:
Malicious Document ↓RAG ↓Retrieved Context ↓LLMThe document may contain instructions intended to manipulate model behavior.
This connects poisoning with:
Indirect Prompt Injection
Therefore RAG security must protect both:
Knowledge Integrity+Instruction Integrity4 — Model Poisoning
Section titled “4 — Model Poisoning”Instead of manipulating data, an attacker may manipulate the model artifact itself.
Conceptually:
Trusted Model ↓Attacker Modification ↓Poisoned Model ↓ProductionThis connects directly to AI supply-chain security.
Model Poisoning Attack Path
Section titled “Model Poisoning Attack Path”Attacker ↓Model Repository ↓Replace / Modify Model ↓Deployment Pipeline ↓ProductionPotential outcomes include:
-
Modified model behavior
-
Reduced reliability
-
Hidden behavior
-
Backdoors
-
Integrity loss
Model Integrity
Section titled “Model Integrity”Organizations should know:
Which Model?
Which Version?
Which Source?
Which Checksum?
Who Approved It?This helps identify unauthorized modification.
Backdoored Models
Section titled “Backdoored Models”A backdoor is hidden behavior designed to activate under particular conditions.
Conceptually:
Normal Input ↓Normal Behaviorbut:
Specific Trigger ↓Unexpected BehaviorThe model may otherwise appear normal.
Trigger-Based Behavior
Section titled “Trigger-Based Behavior”Imagine a model behaves correctly during normal testing.
99% of Inputs ↓Expected BehaviorBut a particular pattern activates hidden behavior:
Special Trigger ↓Manipulated ResponseThis makes backdoors particularly difficult to detect.
Example Concept
Section titled “Example Concept”Normal:
Review this security configuration.Result:
Identifies security risks.Trigger present:
Specific hidden pattern ↓Model suppresses certain findings.The exact implementation varies by attack and model.
The important concept is that malicious behavior may be conditional.
Poisoning Through User Feedback
Section titled “Poisoning Through User Feedback”Some AI systems learn from feedback.
Example:
User Interaction ↓Feedback ↓Future Model ImprovementIf attackers can manipulate large amounts of feedback:
Attacker ↓Fake Feedback ↓Learning Pipelinethe improvement mechanism itself may become an attack surface.
Feedback Should Not Automatically Become Trusted Training Data
Section titled “Feedback Should Not Automatically Become Trusted Training Data”Weak:
All User Feedback ↓Training DatasetStronger:
User Feedback ↓Validation ↓Quality Review ↓Approved DatasetPoisoning Through Synthetic Data
Section titled “Poisoning Through Synthetic Data”Organizations increasingly use AI-generated synthetic datasets.
Architecture:
LLM ↓Synthetic Examples ↓Training DatasetThis creates another dependency.
Ask:
Which model generated the data?
Which prompt was used?
Was the output reviewed?
Can incorrect patterns propagate?Synthetic does not automatically mean trustworthy.
Poisoning Through Public Data
Section titled “Poisoning Through Public Data”Public data sources may include:
-
Websites
-
Forums
-
Open datasets
-
Public repositories
-
Internet content
Attackers may influence some of these sources.
Architecture:
Internet ↓Data Collection ↓Training / RAGThis means public content should not automatically receive enterprise trust.
Poisoning Through Compromised Internal Accounts
Section titled “Poisoning Through Compromised Internal Accounts”An attacker may not need access to the AI platform.
Suppose:
Compromised Employee Account ↓Internal Wiki ↓Document Modified ↓RAG IngestionThe poisoning enters through an existing enterprise system.
This demonstrates why AI security must integrate with traditional:
-
IAM
-
Endpoint security
-
Change management
-
Monitoring
Poisoning Through Automated Ingestion
Section titled “Poisoning Through Automated Ingestion”Automation can increase risk.
Weak:
New Document ↓Automatically Indexed ↓Production RAGNo trust validation exists.
Stronger:
New Document ↓Source Validation ↓Classification ↓Approval / Policy ↓Production IndexNot every workflow requires manual approval, but the trust decision should be intentional.
Dataset Provenance
Section titled “Dataset Provenance”Dataset provenance answers:
Where did this data come from?
Useful metadata includes:
Dataset Name
Source
Owner
Version
Creation Date
Modification Date
Classification
Approval StatusWithout provenance:
Model Produces Unexpected Behavior ↓Which Data Caused It? ↓UnknownInvestigation becomes extremely difficult.
Data Lineage
Section titled “Data Lineage”Provenance identifies the source.
Data lineage tracks how data moves and changes.
Example:
Source Dataset ↓Cleaning ↓Filtering ↓Labeling ↓Training Dataset ↓Fine-TuningSecurity teams should understand this chain.
Dataset Versioning
Section titled “Dataset Versioning”Instead of:
training-data.csvwith continuous undocumented changes, maintain controlled versions.
Conceptually:
Dataset v1Dataset v2Dataset v3Then:
Model v5 ↓Trained Using ↓Dataset v3This supports reproducibility.
Model Provenance
Section titled “Model Provenance”Model provenance should connect:
Base Model +Dataset +Configuration +Training Process ↓Resulting ModelExample:
Model:SecurityAssistant-v4
Base Model:Approved-Model-v3
Fine-Tuning Dataset:Security-Dataset-v7
Training Pipeline:ML-Pipeline-04
Approval:CompletedModel Lineage
Section titled “Model Lineage”A mature organization should be able to answer:
Production Model ↓Which Fine-Tuned Model? ↓Which Base Model? ↓Which Dataset? ↓Which Pipeline?This is extremely valuable during incidents.
Protecting Training Data
Section titled “Protecting Training Data”Security controls may include:
-
Restricted write access
-
Approved data sources
-
Dataset versioning
-
Change logging
-
Integrity verification
-
Peer review
-
Separation of duties
Dataset Access Control
Section titled “Dataset Access Control”Ask:
Who can read?
Who can write?
Who can approve?
Who can delete?Write access is particularly important because poisoning is an integrity attack.
Separation of Duties
Section titled “Separation of Duties”Weak:
Developer ↓Modify DatasetTrain ModelApprove ModelDeploy ProductionStronger:
Data Team ↓Dataset
ML Team ↓Training
Security / Validation ↓Review
Production Pipeline ↓DeploymentThe exact structure depends on organizational size.
The principle is to avoid unnecessary concentration of control.
Dataset Integrity Verification
Section titled “Dataset Integrity Verification”Where appropriate, organizations may maintain:
Dataset ↓Integrity Record ↓Expected?Unexpected modifications can then trigger investigation.
Change Review
Section titled “Change Review”High-value datasets may require controlled changes.
Example:
Dataset Change ↓Review ↓Approved? ├── No → Reject └── Yes → New VersionProtecting RAG Knowledge Sources
Section titled “Protecting RAG Knowledge Sources”For RAG:
Approved Repository ↓Controlled Ingestion ↓Vector StoreProtect:
-
Source permissions
-
Source ownership
-
Document approval
-
Change history
-
Ingestion identities
RAG Source Allowlisting
Section titled “RAG Source Allowlisting”Instead of:
Any Available Repository ↓RAGprefer:
Approved Knowledge Sources ↓RAGThis reduces poisoning opportunities.
Knowledge Source Trust Levels
Section titled “Knowledge Source Trust Levels”Organizations may classify sources.
Example:
| Source | Trust |
|---|---|
| Approved Security Standard | High |
| Internal Wiki | Medium |
| User Upload | Low |
| Internet Content | Untrusted |
Trust can influence retrieval and response behavior.
Protecting Vector Index Integrity
Section titled “Protecting Vector Index Integrity”Restrict who can:
Insert Vectors
Update Vectors
Delete Vectors
Create CollectionsRetrieval users generally should not need these permissions.
Protecting Model Artifacts
Section titled “Protecting Model Artifacts”A secure model lifecycle may look like:
Model Source ↓Integrity Validation ↓Security Evaluation ↓Approved Registry ↓Controlled DeploymentProduction should not arbitrarily download model artifacts from uncontrolled sources.
Model Signing and Integrity
Section titled “Model Signing and Integrity”Where supported, organizations may use:
-
Checksums
-
Digital signatures
-
Signed artifacts
-
Immutable registries
Conceptually:
Model Artifact ↓Integrity Verification ↓Trusted? ├── No → Reject └── Yes → ContinuePoisoning Detection Is Difficult
Section titled “Poisoning Detection Is Difficult”Poisoning can be difficult to detect because the model may still work normally.
For example:
Normal Inputs ↓Correct Resultswhile:
Specific Scenario ↓Manipulated ResultTraditional availability monitoring may show:
System Healthywhile model integrity has been compromised.
Detection Requires Multiple Layers
Section titled “Detection Requires Multiple Layers”Useful approaches may include:
Data Monitoring+Model Evaluation+Source Monitoring+Behavior Monitoring+Change AuditingNo single control is sufficient.
Dataset Anomaly Detection
Section titled “Dataset Anomaly Detection”Security and ML teams may look for:
-
Unexpected label changes
-
Unusual new samples
-
Duplicate suspicious examples
-
Distribution changes
-
Unexpected source changes
The exact techniques depend on the dataset and model.
Source Monitoring
Section titled “Source Monitoring”Monitor:
Who changed the document?
When?
What changed?
Was the source approved?This is particularly important for RAG knowledge bases.
Model Behavior Evaluation
Section titled “Model Behavior Evaluation”Maintain expected evaluation cases.
Example:
Security Question AExpected Behavior
Security Question BExpected Behavior
Security Question CExpected BehaviorAfter model changes:
New Model ↓Regression Evaluation ↓Unexpected Security Behavior?Security Regression Tests
Section titled “Security Regression Tests”Security-specific tests may check:
-
Sensitive information handling
-
Authorization behavior
-
Security policy recommendations
-
Agent tool restrictions
-
Known safety requirements
This helps detect unexpected behavior after model or dataset changes.
Canary Tests
Section titled “Canary Tests”Organizations may maintain controlled test inputs that should consistently produce known security behavior.
Example:
TEST-SECURITY-SCENARIO-001 ↓Expected Security ResponseUnexpected changes may trigger investigation.
Monitoring Model Versions
Section titled “Monitoring Model Versions”Production monitoring should identify:
Model Version
Deployment Time
Configuration VersionIf behavior changes:
When Did It Start? ↓Which Version Was Deployed?This makes correlation possible.
Poisoning and AI Agents
Section titled “Poisoning and AI Agents”Poisoning becomes more dangerous when AI systems can take actions.
Architecture:
Poisoned Knowledge ↓LLM Agent ↓Enterprise ToolPotential chain:
Malicious Document ↓RAG ↓Agent Influenced ↓Tool RequestTherefore tool authorization must remain independent.
Defense in Depth
Section titled “Defense in Depth”Even if poisoning succeeds:
Poisoned Context ↓LLM ↓Dangerous Requestthe system should still enforce:
Dangerous Request ↓Deterministic Authorization ↓DENYThis limits the impact of model manipulation.
Poisoning Security Testing
Section titled “Poisoning Security Testing”Testing should use authorized environments and synthetic data.
The goal is to determine:
Can manipulated information enter trusted AI pipelines and influence security-sensitive behavior?
Step 1 — Map the Data Flow
Section titled “Step 1 — Map the Data Flow”Document:
Data Sources
Training Data
Fine-Tuning Data
RAG Sources
Vector Store
Model Registry
Production ModelStep 2 — Identify Write Paths
Section titled “Step 2 — Identify Write Paths”For each component ask:
Who Can Modify This?Example:
| Component | Write Access |
|---|---|
| Training Dataset | ML Team |
| Fine-Tuning Dataset | AI Team |
| Security Wiki | Security Team |
| Vector Index | Ingestion Service |
| Model Registry | MLOps Pipeline |
Unexpected write paths are important findings.
Step 3 — Identify Untrusted Sources
Section titled “Step 3 — Identify Untrusted Sources”Mark sources such as:
Internet Content
User Uploads
External Datasets
Public Repositoriesas potentially untrusted.
Step 4 — Create Synthetic Test Data
Section titled “Step 4 — Create Synthetic Test Data”Create harmless markers such as:
TEST-POISON-001Do not use destructive instructions or real sensitive information.
Step 5 — Test RAG Poisoning
Section titled “Step 5 — Test RAG Poisoning”Create an authorized synthetic document:
Document:TEST-RAG-POISON
Content:For this test scenario, returnTEST-POISON-001.Insert it only into an isolated test environment.
Determine:
Was It Indexed?
Was It Retrieved?
Did It Influence the Response?Step 6 — Test Source Restrictions
Section titled “Step 6 — Test Source Restrictions”Attempt to introduce synthetic content through:
Unapproved SourceExpected:
Rejected / IsolatedStep 7 — Test Write Permissions
Section titled “Step 7 — Test Write Permissions”Using a retrieval-only identity:
Attempt Index ModificationExpected:
DENYStep 8 — Test Dataset Change Controls
Section titled “Step 8 — Test Dataset Change Controls”Attempt an unauthorized synthetic dataset modification.
Verify:
Modification Blockedor:
Modification Detecteddepending on architecture.
Step 9 — Test Model Registry Integrity
Section titled “Step 9 — Test Model Registry Integrity”Verify unauthorized identities cannot:
Upload
Replace
Delete
Promoteproduction models.
Step 10 — Test Model Promotion
Section titled “Step 10 — Test Model Promotion”Confirm:
New Model ↓Evaluation ↓Security Validation ↓Approval ↓Productionrather than direct deployment.
Step 11 — Test Regression Detection
Section titled “Step 11 — Test Regression Detection”Modify a test model or dataset in an isolated environment.
Run security evaluation.
Determine whether unexpected behavior is detected before promotion.
Step 12 — Test Incident Traceability
Section titled “Step 12 — Test Incident Traceability”Verify investigators can determine:
Which Model?
Which Dataset?
Which Version?
Which Source?
Which User Changed It?
When?Poisoning Incident Response
Section titled “Poisoning Incident Response”Suppose suspicious model behavior is discovered.
A useful response process is:
Detect ↓Contain ↓Identify Model Version ↓Identify Dataset / Knowledge Sources ↓Review Recent Changes ↓Identify Unauthorized Modification ↓Restore Trusted Version ↓Revalidate ↓MonitorRAG Poisoning Response
Section titled “RAG Poisoning Response”For RAG:
Suspicious Response ↓Identify Retrieved Sources ↓Locate Poisoned Document ↓Disable Source ↓Remove Indexed Chunks ↓Invalidate Cache ↓Review Historical Retrieval ↓Restore Trusted Content ↓ReindexTraining Poisoning Response
Section titled “Training Poisoning Response”For training or fine-tuning:
Suspicious Model ↓Identify Model Version ↓Identify Training Dataset ↓Compare Dataset Versions ↓Locate Manipulated Data ↓Restore Trusted Dataset ↓Retrain / Restore Model ↓ValidateModel Poisoning Response
Section titled “Model Poisoning Response”For model artifact compromise:
Compromised Model ↓Remove From Production ↓Block Artifact ↓Identify Registry Modification ↓Restore Verified Model ↓Rotate Credentials if Required ↓Investigate Deployment HistoryExample — RAG Poisoning Finding
Section titled “Example — RAG Poisoning Finding”Finding:Untrusted Content Can Enter Production RAG Knowledge Base
Affected Component:Enterprise Security Assistant
Observed Behavior:Documents created through an uncontrolled source areautomatically indexed into the production knowledge base.
Potential Impact:An attacker may introduce misleading information orIndirect Prompt Injection content that influences futureAI responses.
Recommendation:Restrict production ingestion to approved sources,maintain document provenance, enforce controlled writeaccess and monitor knowledge-base modifications.Example — Fine-Tuning Dataset Finding
Section titled “Example — Fine-Tuning Dataset Finding”Finding:Fine-Tuning Dataset Can Be Modified Without Review
Affected Component:Enterprise AI Fine-Tuning Pipeline
Observed Behavior:Development users can modify training examples used forproduction fine-tuning without approval or version control.
Potential Impact:Unauthorized or malicious samples could influenceproduction model behavior.
Recommendation:Implement dataset ownership, versioning, restricted writeaccess, change review and traceability between datasetversions and resulting models.Example — Model Integrity Finding
Section titled “Example — Model Integrity Finding”Finding:Production Model Integrity Is Not Verified
Affected Component:Model Deployment Pipeline
Observed Behavior:The deployment pipeline retrieves a model artifact withoutvalidating its expected integrity.
Potential Impact:A modified or replaced model could be deployed withoutdetection.
Recommendation:Use trusted model registries, maintain approved artifactidentifiers and implement appropriate integrity validationbefore production deployment.Example — Production Model Backdoor Concern
Section titled “Example — Production Model Backdoor Concern”Finding:Production Model Has No Security Regression Validation
Affected Component:Model Promotion Process
Observed Behavior:New fine-tuned models are deployed after functionalevaluation but without security-specific regression tests.
Potential Impact:Unexpected or trigger-dependent security behavior mayreach production without detection.
Recommendation:Maintain security evaluation datasets and regression testscovering sensitive information, authorization, securitypolicy behavior and agent tool restrictions.Poisoning Defense Architecture
Section titled “Poisoning Defense Architecture”A strong architecture combines multiple controls.
Trusted Sources ↓Provenance ↓Access Control ↓Integrity Monitoring ↓Versioning ↓Controlled Processing ↓Security Evaluation ↓Approved Model / Knowledge Base ↓Runtime Guardrails ↓MonitoringPrevention
Section titled “Prevention”Prevent poisoning through:
-
Trusted sources
-
Restricted write access
-
Controlled ingestion
-
Dataset governance
-
Model registry security
-
Separation of duties
Detection
Section titled “Detection”Detect poisoning through:
-
Change monitoring
-
Data validation
-
Model evaluation
-
Security regression testing
-
Retrieval monitoring
-
Version comparison
Containment
Section titled “Containment”Contain poisoning through:
-
Disable compromised sources
-
Remove malicious vectors
-
Block affected models
-
Revoke compromised identities
-
Stop model promotion
Recovery
Section titled “Recovery”Recover through:
Trusted Dataset
Trusted Knowledge Base
Verified Model
Known-Good Configurationthen revalidate before returning to production.
Model and Data Poisoning Checklist
Section titled “Model and Data Poisoning Checklist”Data Sources
Section titled “Data Sources”-
Sources inventoried.
-
Trusted and untrusted sources classified.
-
Ownership defined.
-
Provenance maintained.
Training Data
Section titled “Training Data”-
Write access restricted.
-
Dataset versions maintained.
-
Changes logged.
-
Data integrity monitored.
-
Unauthorized changes detectable.
Fine-Tuning
Section titled “Fine-Tuning”-
Base model approved.
-
Dataset approved.
-
Dataset version recorded.
-
Training process traceable.
-
Resulting model versioned.
-
Production sources approved.
-
Ingestion controlled.
-
Source provenance maintained.
-
Vector write permissions restricted.
-
Poisoned documents can be removed.
Models
Section titled “Models”-
Model source known.
-
Model integrity verified where appropriate.
-
Production registry protected.
-
Unauthorized replacement prevented.
-
Model versions tracked.
Backdoors
Section titled “Backdoors”-
Security regression tests maintained.
-
Trigger-dependent behavior considered.
-
Model changes evaluated.
-
Unexpected security behavior investigated.
Monitoring
Section titled “Monitoring”-
Dataset changes monitored.
-
Knowledge-base changes monitored.
-
Model registry changes monitored.
-
Production model versions observable.
-
Retrieval sources traceable.
Incident Response
Section titled “Incident Response”-
Poisoned documents can be isolated.
-
Vector indexes can be rebuilt.
-
Dataset versions can be restored.
-
Models can be rolled back.
-
Historical changes can be investigated.
Common Beginner Mistakes
Section titled “Common Beginner Mistakes”Mistake 1 — Thinking Poisoning Only Happens During Training
Section titled “Mistake 1 — Thinking Poisoning Only Happens During Training”Poisoning may affect training, fine-tuning, RAG or model artifacts.
Mistake 2 — Trusting Internal Documents Automatically
Section titled “Mistake 2 — Trusting Internal Documents Automatically”A compromised internal account may modify enterprise knowledge.
Mistake 3 — Allowing Every Document Into RAG
Section titled “Mistake 3 — Allowing Every Document Into RAG”Production knowledge sources should have defined trust policies.
Mistake 4 — Ignoring Dataset Versioning
Section titled “Mistake 4 — Ignoring Dataset Versioning”Without versions, identifying when poisoning occurred becomes difficult.
Mistake 5 — Protecting Model Confidentiality but Not Integrity
Section titled “Mistake 5 — Protecting Model Confidentiality but Not Integrity”Preventing model theft is important, but unauthorized modification can be equally serious.
Mistake 6 — Giving Too Many Users Dataset Write Access
Section titled “Mistake 6 — Giving Too Many Users Dataset Write Access”Poisoning attacks target write paths.
Mistake 7 — Automatically Using User Feedback for Training
Section titled “Mistake 7 — Automatically Using User Feedback for Training”Feedback should pass through validation and governance.
Mistake 8 — Trusting Synthetic Data Automatically
Section titled “Mistake 8 — Trusting Synthetic Data Automatically”AI-generated information can still contain incorrect or manipulated patterns.
Mistake 9 — Testing Only Overall Model Accuracy
Section titled “Mistake 9 — Testing Only Overall Model Accuracy”Targeted poisoning may affect specific scenarios while overall performance remains acceptable.
Mistake 10 — Forgetting Agent Impact
Section titled “Mistake 10 — Forgetting Agent Impact”Poisoned AI behavior becomes more serious when the AI can take enterprise actions.
AI Security Engineer Perspective
Section titled “AI Security Engineer Perspective”When investigating poisoning risk, ask:
What information influences this AI system?
Where does that information originate?
Who can modify it?
Which sources are trusted?
How are datasets versioned?
Can user-controlled information enter training?
Can untrusted documents enter RAG?
Who can modify the vector index?
Who can replace the model?
Can we verify model provenance?
Can we connect a model to its training dataset?
Do we test security behavior after model changes?
Can we identify the source of a suspicious response?
Can we restore a known-good version?These questions move security from:
Is the AI Available?to:
Can We Trust What the AIHas Learned and What It Uses?Interview Perspective
Section titled “Interview Perspective”You may be asked:
What is data poisoning in AI?
A strong answer is:
Data poisoning is an integrity attack where malicious or manipulated samples are introduced into training, fine-tuning or knowledge data with the goal of influencing AI behavior. The impact may range from general performance degradation to targeted or trigger-dependent behavior.
Another question may be:
What is the difference between training data poisoning and RAG poisoning?
A strong answer is:
Training data poisoning modifies information used to train or fine-tune the model and may therefore change the model itself. RAG poisoning manipulates external knowledge retrieved at inference time, so the underlying model may remain unchanged while its responses are influenced by poisoned context.
Another question may be:
What is a backdoored AI model?
A strong answer is:
A backdoored model contains hidden behavior that may activate when a specific trigger or condition appears while otherwise behaving normally. This makes the issue difficult to identify through general model-performance testing alone.
Another question may be:
How would you protect an AI system from poisoning?
A strong answer is:
I would establish trusted data and model sources, maintain provenance and versioning, restrict write access, control RAG ingestion, protect model and vector registries, monitor changes, run security regression evaluations and maintain the ability to restore known-good datasets, indexes and model versions.
Another question may be:
Why is provenance important during a poisoning incident?
A strong answer is:
Provenance allows investigators to trace a production model or response back to the model version, dataset, knowledge source and processing pipeline that influenced it. Without that traceability, identifying the source and scope of poisoning becomes significantly harder.
Key Takeaways
Section titled “Key Takeaways”AI poisoning attacks target integrity.
The attack may occur through:
Training Data+Fine-Tuning Data+RAG Knowledge+Vector Indexes+Model Artifacts+Feedback PipelinesA useful defensive model is:
Trusted Source ↓Provenance ↓Restricted Modification ↓Versioning ↓Integrity Monitoring ↓Security Evaluation ↓Controlled Deployment ↓Runtime MonitoringRemember:
-
Know where models and data come from.
-
Protect dataset write access.
-
Version training and fine-tuning data.
-
Control production RAG ingestion.
-
Protect vector index integrity.
-
Protect model registries.
-
Monitor changes.
-
Test security behavior after updates.
-
Maintain model and data lineage.
-
Prepare rollback and recovery procedures.
Most importantly:
AI systems cannot be trusted if attackers can silently control the information they learn from, retrieve or execute against.
What’s Next?
Section titled “What’s Next?”➡️ 12 — AI Security Monitoring, Logging and Incident Response
Preventing attacks is only one part of AI security.
Enterprise security teams must also be able to answer:
What happened?
Who interacted with the AI?
Which model was used?
Which knowledge was retrieved?
Which tools were called?
Was sensitive information exposed?
Was the model or dataset changed?In the next lesson, you will learn how to design security visibility across the AI stack, including:
-
AI security telemetry
-
Prompt and response monitoring
-
Privacy-aware logging
-
Model activity monitoring
-
RAG retrieval logs
-
Vector database activity
-
Agent tool-call logging
-
Model and dataset change monitoring
-
AI security detections
-
SIEM integration
-
AI incident investigation
-
Prompt Injection incidents
-
Sensitive data exposure incidents
-
RAG poisoning investigations
-
Agent compromise investigations
-
Model rollback and containment
-
AI incident response playbooks
You will move from:
How Do We Prevent AIModels and Data FromBeing Manipulated?to:
How Do We Detect,Investigate and RespondWhen Something Goes Wrong?➡️ Next: 12 — AI Security Monitoring, Logging and Incident Response