Safety, Security & Responsible AI·Question 25 of 70Intermediate

How can an attacker poison training data or plant a backdoor in a model, and how would you catch it?

Type it the way you would explain it to an interviewer. A few sentences is enough; you can't break anything.

Model answer: the part to lead with

Poisoning (LLM05:2026, LLM04 in 2025), which now includes fine-tuning subversion, means corrupting data so the model learns something the attacker chose. There are three realistic entry points, and they differ a lot in practicality.

Full worked answer

Poisoning (LLM05:2026, LLM04 in 2025), which now includes fine-tuning subversion, means corrupting data so the model learns something the attacker chose. There are three realistic entry points, and they differ a lot in practicality.

Pretraining corpora. Web-scale scraping is cheap to poison because the web is not fixed: buy expired domains that appear in a known crawl list, edit collaboratively-edited sources shortly before a snapshot is taken, or seed content that you know will be scraped. Research has shown that poisoning a small fraction of a web-scale dataset is achievable for a modest budget. Most application teams do not control this, but it is why weights provenance matters.

Fine-tuning and preference data. This is the practical one. A vendor supplies labelled data, or you crowdsource preferences, and a small number of crafted examples goes a long way. Alignment-relevant poisoning is especially cheap because the fine-tuning sets are small.

The RAG index. The version almost every team actually faces, and it needs no training at all: if user-generated content, supplier catalogues or scraped pages feed your corpus, the attacker just writes a document.

A backdoor is the nastiest shape: a trigger phrase maps to attacker-chosen behaviour, and clean-input accuracy is untouched. That is what makes it hard, and it is the point to make in an interview: you cannot benchmark a backdoor out. Your eval suite passes, because the trigger is not in it, and the trigger space is effectively unsearchable.

So detection shifts from testing to provenance and process. Pin dataset snapshots by hash and record a data bill of materials. Curate and rank sources rather than scraping broadly. Deduplicate, since memorisation and poisoning both track duplication. For preference data, look for label anomalies and per-annotator outliers. For third-party weights, prefer known provenance, verify hashes and signatures, and use safetensors so loading is not itself code execution.

For the RAG index, which is where your leverage really is: separate namespaces by trust level, attach provenance to every chunk, require authenticated writes, and treat a retrieved chunk as untrusted text no matter how it got in.

What a good answer covers

  • Poisoning (LLM05:2026, LLM04 in 2025), which now includes fine-tuning subversion, means corrupting data…
  • There are three realistic entry points, and they differ a lot in practicality
  • Web-scale scraping is cheap to poison because the web is not fixed
  • Research has shown that poisoning a small fraction of a web-scale dataset is achievable for a modest budget
  • Most application teams do not control this, but it is why weights provenance matters

Key terms: Pretraining corpora · Fine-tuning and preference data · The RAG index

Interviewer follow-ups to expect

  1. If you inherit an open-weights model from a hub, what would actually convince you it has no backdoor?

  2. How does poisoning the RAG index differ, operationally, from poisoning fine-tuning data?

Worked answer from AI-Engineer-Interview-Questions by Om (MIT), reformatted for LLM Prep · answer text last updated 6 November 2026 · scoring and review schedule by LLM Prep