RAG Pipeline Security Assessment
Retrieval turns whatever is in your knowledge base into part of the prompt. Anyone who can write to it, or bias what gets retrieved, can control your model’s answers without ever talking to it. We test the whole pipeline, from the documents in to the answer out.
Book a ConsultationAI Security › RAG Pipeline Security Assessment
Whoever writes to the corpus writes the answer
A retrieval-augmented system has three places to attack: the knowledge sources the documents come from, the retrieval layer that embeds, ranks, isolates and filters them, and the generation step that turns retrieved chunks into an answer. The most common business impact of a poisoned corpus isn’t exfiltration. It is that an attacker controls the answer a legitimate user receives, and where that answer feeds an automated decision, controls the decision too.
These attacks are quiet. The attacker writes a document, or stuffs one with terms so it out-ranks the authoritative source, and waits. Every query looks legitimate, and without provenance a poisoned answer is indistinguishable from a real one. The other half of the risk is leakage: retrieval that fetches first and filters afterwards leaks through summaries, counts and ranking behavior, and a shared index can hand one tenant another tenant’s documents.
Generic prompt-injection defenses don’t fix any of this; it needs controls in the retrieval layer itself. Findings are ranked by what an attacker gains, not by how clever the payload was. Retrieval and generation are probabilistic, so every result is reported as a success rate over a stated number of trials, on a pinned model version.
Documents in, retrieval, answer out
Knowledge-source poisoning
Can a planted low-trust document be asserted as the authoritative answer? We test every ingestion path into each corpus and who can write to it, trigger-phrase backdoors that stay dormant until a matching query arrives, and feedback loops where production output flows back into retrieval.
Retrieval manipulation
Keyword-stuffed adversarial passages that out-rank your curated documents, attacker-controllable metadata carried into context, and citation spoofing that makes an attacker-chosen source look like the authority behind an answer.
Injection through retrieved content
Instructions hidden in documents the system retrieves: invisible text, document properties, image chunks. We test whether a retrieved chunk can make the model act, including retrieved content that drives a tool call or sends data out.
Retrieval-time access control
Asking for documents a user can’t open directly. Does retrieval filter by identity at query time, or retrieve first and filter afterwards? We test document-level permissions, cross-namespace retrieval, and deleted or revoked documents still sitting in the index.
Cross-tenant isolation
Two real isolated tenants: can tenant A retrieve tenant B’s documents through the model, does a canary from one appear in the other’s context, and does a shared vector namespace rely on post-filtering? Semantic caches that ignore identity are tested too.
Leakage & enumeration
Canary documents regurgitated verbatim, document titles, paths, authors and the mere existence of documents leaking through answers, and corpus enumeration by repeated targeted queries. We also check whether a user can tell which document produced which claim.
From the ingestion map to a confirmed fix
Scope & authorize
We name the system, its environment, the models it calls and every corpus, vector store and third party in the path. We agree the canary documents, the test corpus or namespace we will write to, and how every write is removed.
Map the pipeline
Every corpus with its ingestion paths and the trust level of its content: curated internal, user-uploaded, web-scraped or third-party feed. Chunking, embedding and re-ranking, namespaces and isolation, and where retrieval filters by identity.
Baseline
We record normal answers and retrieval behavior, pin the model version and sampling settings, and measure variance so the trial count is set before any attack is run.
Hands-on testing
Poisoning, backdoors and ranking manipulation with canary documents; injection through retrieved content; access control and isolation with two tenants. Every result records the input, trial count and success rate.
Chain & impact
Who can plant the document, what it changes, and what it reaches: a corrupted answer, an automated decision, another tenant’s data, an outbound request. Each chain carries its break point and whether your telemetry would have seen it.
Report, walkthrough & retest
An engineering walkthrough and a separate executive briefing. Once you have fixed things, we retest each finding at its original trial count.
Poison the test corpus, never yours
- Never poison a production corpus — before we plant a single document we confirm the corpus we write to isn’t shared with production; poisoning a corpus that turns out to be live is the failure we design the engagement around
- Canary documents, never real data — every poisoning and leakage test uses seeded canaries; we never test exfiltration with genuine customer documents or personal data
- Every write logged and removed — each planted document and memory entry goes in a write/revert register and is reverted at the end of each day; nothing is left in your index
- Two real tenants — at least two isolated test tenants plus a privileged and an unprivileged persona, provisioned before testing starts; isolation can’t be proven with one
- Written authorization, including third parties — model providers, hosted vector stores and SaaS sources in the call path each have their own terms, and we confirm in writing that testing against them is permitted
- Production or staging, decided up front — a staging corpus often holds different documents and different permissions, so a staging result needs your written confirmation of parity, and the report states every difference we find
- A cost cap and an abort plan — an agreed spend ceiling for adversarial queries, a named contact and a stop-word; anything that looks like real data exposure stops testing immediately
How findings are mapped
Community frameworks, not law. Status as checked in October 2026, with the agentic and ATLAS mappings current as of November 2026; we confirm the current versions at kickoff and record the date in the report.
| Framework | Status | How we use it |
|---|---|---|
| OWASP Top 10 for LLM Applications 2026 | Guidance · current edition | Cited with the year, because the numbering changed: LLM09:2026 Vector & Embedding Weaknesses, LLM05:2026 Data & Model Poisoning, LLM01:2026 Prompt Injection, LLM02:2026 Sensitive Information Disclosure, LLM07:2026 Misinformation. |
| OWASP Top 10 for Agentic Applications published Dec 9, 2025 | Guidance · ASI01–ASI10 | Where retrieval feeds an agent: corpus poisoning, ranking manipulation and isolation failures map to ASI06 Memory & Context Poisoning, retrieval permission bypass to ASI03 Identity & Privilege Abuse, instructions planted in a document to ASI01 Agent Goal Hijack. |
| MITRE ATLAS 2026.10 | Knowledge base · adversary techniques | Cross-tenant retrieval leakage and retrieval access-control bypass carry AML.T0085.000. IDs come from our tooling’s class table only; we never synthesize one to complete a mapping. |
What you get
- Pipeline and corpus map — every corpus, ingestion path and vector store, with who can write to it and the trust level of its content, as part of your AI bill of materials
- Attack chains, told end to end — from the document an attacker can plant to the answer, decision or data it reaches, with success rate over N trials, break point and detectability
- Impact-ranked findings — scored on who can plant the content, what it gains and how reliably it works, with the model version, exact input and trial count needed to reproduce each one
- Isolation results — what crossed between tenants, sessions and namespaces, and whether retrieval filters by identity at query time
- Findings, control gaps and coverage gaps, kept apart — so a missing control is never presented as a breach, and anything not assessed is listed with the reason
- Retrieval-layer remediation — provenance tagging and trust weighting, scanning documents at ingest, ranking that rejects stuffed passages, and permissions enforced at retrieval time rather than in the interface, ordered by durability
- Detection guidance — what would show a poisoned answer or a boundary-crossing retrieval in your logs, with blind spots ranked first
- Safe deployment checklist — tailored to what we found: what to verify before your next data source or corpus goes live
- Retest of fixes — one round, at the original trial count
Where retrieval testing connects
Find out who really writes your answers.
Testing starts with an agreed scope, a corpus we can safely write to, and two test tenants. The first conversation is free.
Get in Touch