Research reportAgentic security

Poisoned memory and retrieval: what published attacks show

RAG poisoning and memory poisoning plant text that superintelligence (SI) agents later retrieve and act on. What published attacks, disclosed cases and tested defenses show.

Cover of the full report: Poisoned memory and retrieval: what published attacks show
The research behind this article, with every source listed. 20 pages.

Key points

From the Summary of the full report

  1. RAG poisoning plants text in a store that a retrieval-augmented generation (RAG) system searches, so that a later query retrieves it and the model acts on it. Memory poisoning plants it in what an agent keeps between sessions [3, 5].
  2. PoisonedRAG, a knowledge corruption attack published at USENIX Security 2025, reported a 90% attack success rate when it injected five malicious texts for each target question into a knowledge database with millions of texts [7].
  3. Every attack reviewed starts with a way to put text into something the system reads: edits to public pages, one file in a local folder, a post in a public channel or ordinary queries to an agent with a shared memory (derived for this report) [7, 10, 13, 31].
  4. Planted memories have reached production assistants. Researchers wrote lasting memories into two consumer assistants in 2024 and 2025 through a document or web page the user opened, and the vendors' responses covered the data leak route or rated the risk low [27, 28].

RAG poisoning plants text in a store that a retrieval-augmented generation (RAG) system searches, so that a later query retrieves it and the model answers or acts on it [5]. Memory poisoning does the same to what an agent keeps between sessions [3]. Published attacks show how little text it takes: PoisonedRAG, presented at USENIX Security 2025, reported a 90% attack success rate with five malicious texts for each target question in a knowledge database of millions of texts [7].

This report reads 34 sources: the OWASP, NIST and MITRE entries, 22 papers on attacks and defenses, and disclosed cases of memory poisoning and poisoned retrieval in production SI assistants. It sits beside indirect prompt injection, which tests each channel an agent reads, and prompt injection vs jailbreak, which separates two different failures. Here the planted text waits in storage until a query or a later session brings it back.

What RAG poisoning and memory poisoning are

MITRE ATLAS defines RAG Poisoning (AML.T0070) as injecting malicious content into data a RAG system indexes, for example by placing manipulated documents where it indexes [5]. Its AI Agent Context Poisoning technique (AML.T0080) covers an agent's memory and its threads [5]. OWASP files the agent side under ASI06 Memory and Context Poisoning, which "focuses on persistent corruption of agent memory and retrievable context that propagates across sessions" [3].

Training data poisoning is a separate attack. OWASP's LLM04:2025 entry covers manipulated pre-training, fine-tuning or embedding data [2]. The attacks here change no model weights: AgentPoison, for one, "requires no additional model training or fine-tuning" [12].

How a RAG poisoning attack works

Each attack needs three steps (derived for this report): the planted text gets in, the victim's query retrieves it, and the model acts on it [6, 7, 12, 15]. PoisonedRAG writes each malicious text in two parts, one to meet a retrieval condition and one to meet a generation condition [7]. Its attacker cannot read the knowledge database, see the model's parameters or query the model [7].

Other attacks aim at retrieval itself:

Attack What it plants Reported result
Adversarial passages, EMNLP 2023 Passages optimized for similarity to training queries 50 passages misled more than 94% of questions over financial documents or online forums [8]
BadRAG, preprint Passages retrieved when a query holds trigger words 10 passages (0.04% of the corpus) gave 98.2% retrieval success and raised negative responses from 0.22% to 72% [9]
Phantom, preprint One document retrieved on a natural trigger sequence Ran end to end against a black-box production RAG application that indexes local files [10]
Machine Against the RAG, USENIX Security 2025 One blocker document The system leaves the target query unanswered [11]

These rates are each paper's own, and a benchmark of 13 attacks reports that "BadRAG and Phantom fall short of their original reports, despite faithful reproduction" [21].

Memory poisoning in LLM agents

AgentPoison (NeurIPS 2024) poisoned the memory or knowledge base of three agents, for driving, question answering and health records, and reached an average attack success rate above 80% at a poison rate under 0.1%, with less than 1% impact on benign performance [12]. MINJA needed only ordinary use: an attacker who "behaves like a regular user" wrote malicious records into a shared memory bank through queries and output observations alone, with 98.2% average injection success and 76.8% average attack success [13]. In a May 2026 preprint, a document or web page led an assistant to store a fabricated memory about the user, and among successful retrievals the planted memories caused attacker-intended agentic actions in 60% to 89% of evaluations [15].

One benchmark measured a far lower rate. Agent Security Bench (ICLR 2025) found a 7.92% average attack success rate for its memory poisoning attack [14]. Each figure holds under its own threat model, and together they do not settle how effective memory poisoning is in general [13, 14, 15].

Persistent memory poisoning in production assistants

Researchers have planted memories in deployed assistants:

  • In September 2024, Rehberger showed an untrusted document or website inserting persistent instructions into a consumer chat assistant's long-term memory, leaking what the user typed in later sessions [27]. The fix covered the leak route, and untrusted content could still make the memory tool store memories [27, 34].
  • In February 2025, a delayed, conditional instruction in a document got another vendor's assistant to save attacker-chosen information to long-term memory, which the vendor assessed as an abuse-related risk "with low likelihood and low impact" [28].
  • A 2025 study of 14 attack scenarios against that vendor's assistants included permanent memory poisoning of their saved information, "enabling persistent malicious activity across independent sessions" [30].
  • In August 2024, an instruction posted in a public channel led a workplace messaging assistant to draw data out of private channels the attacker was not in, and the answer's citation did not refer to the attacker's channel [31].

The only in-the-wild count in the sources is promotional. In 60 days of email traffic, one vendor's researchers found 50 attempts from 31 companies to influence assistants' memory for promotional purposes, such as hidden instructions behind summarize buttons [29].

Who can write to what an agent reads

Across the attacks, the attacker needs a way to put text into something the system reads (derived for this report). They got in through edits to public pages, a file in a local folder, insert access to a knowledge database, a post in a public channel, a shared document and a link a user clicked [7, 10, 11, 19, 29, 31]. OWASP's LLM08 entry adds that poisoned data "can originate from insiders, prompts, data seeding, or unverified data providers" [1]. MITRE notes that the adversary may also set a false entry's title, author and creation date [5].

Citations do not always show what was retrieved. In the messaging case the answer's citation did not refer to the attacker's channel [31]. How to check LLM citations against their sources covers checking an answer against the passages it cites, and OWASP also asks for immutable logs of retrieval activities [1].

RAG poisoning defenses and what they measured

Filters that read the text struggled. PoisonedRAG's malicious texts had perplexity "not statistically higher than those of clean texts", and a duplicate filter left its success rate the same [7]. A benchmark of 13 attacks and 7 defenses found that "Detection-based defenses tend to have negligible impact across most attack types" [21]. On the memory side, a four-stage write-time screen rejected 0 of 360 poisoned memories made of plain false statements [16], and an adaptive attack raised one defense's injection rate from 6.2% to 64.6% on one model [15].

Structural defenses report bounded gains. RobustRAG certifies results against a bounded number of malicious passages for certain queries, with 38% certifiable robust accuracy on RealtimeQA [22]. In the same benchmark, TrustRAG's accuracy with no attack fell below plain RAG's in many settings, mostly by more than 20% [21].

The guidance turns to access and history. MITRE's Memory Hardening mitigation calls for authenticating and authorizing memory operations within user, tenant, agent and session scope, recording the source of every update and keeping known good versions for roll-back [5]. It adds that content filtering "does not replace memory access control, isolation, provenance, integrity, or recovery" [5]. Limiting what a poisoned answer can reach is the access side, covered in MCP access control with scoped credentials, allow-lists and audit logs.

What a test of a memory or retrieval path checks

OWASP's GenAI Red Teaming Manual of October 2026 has RAG tests run against dedicated, non-production vector indexes with synthetic data, and when testing reaches production it requires tagged test accounts and attacks that are "non-destructive and non-persistent" [6]. A memory test confirms that a planted instruction was stored, then checks recall in a clean session, since "a write in one account does not establish exposure to other users" [6]. A document test checks whether ingestion accepts the document, retrieval surfaces it and the model treats it as instructions or authoritative advice, and a retrieval test uses the deployed retriever and reranker [6].

Rillor's agentic security tests check whether planted content in memory, retrieved documents or earlier turns changes an agent's later decisions. Rillor tests only systems the client owns or is authorized to test, within a written scope.

Read the full report

The full report adds each attack's threat model and figures, a table of the production cases with their dates and vendor responses, the defenses' measured results and a stage-by-stage test checklist, with all 34 sources.

The full report

Poisoned memory and retrieval: what published attacks show

The research behind this article, with every source listed. 20 pages.

  1. Summary
  2. Background
  3. Method
  4. Findings
  5. Implications
  6. Limits of this analysis
  7. Sources

Sources

  1. LLM08:2025 Vector and Embedding Weaknesses, OWASP Top 10 for LLM Applications 2025. OWASP GenAI Security Project, 28 April 2025, viewed 8 November 2026. https://genai.owasp.org/llmrisk/llm082025-vector-and-embedding-weaknesses/
  2. LLM04:2025 Data and Model Poisoning, OWASP Top 10 for LLM Applications 2025. OWASP GenAI Security Project, 5 May 2025, viewed 8 November 2026. https://genai.owasp.org/llmrisk/llm042025-data-and-model-poisoning/
  3. OWASP Top 10 For Agentic Applications 2026, Version 2026 (ASI06 Memory & Context Poisoning, pages 24 to 26). OWASP Gen AI Security Project, Agentic Security Initiative, December 2025, viewed 8 November 2026. https://genai.owasp.org/download/52117/?tmstv=1765059207
  4. ATLAS data, release 2026.10 (techniques AML.T0070, AML.T0071 and AML.T0080, mitigation AML.M0031). MITRE, 28 October 2026, viewed 8 November 2026. https://github.com/mitre-atlas/atlas-data/blob/main/dist/v6/ATLAS-2026.10.yaml
  5. GenAI Red Teaming Manual, Version 1.0: A Practical Guide for Adversarial Testing of Generative AI Models & Systems. OWASP GenAI Security Project, October 2026, viewed 8 November 2026. https://genai.owasp.org/download/58204/?tmstv=1792386768
  6. PoisonedRAG: Knowledge Corruption Attacks to Retrieval-Augmented Generation of Large Language Models. Wei Zou, Runpeng Geng, Binghui Wang and Jinyuan Jia, USENIX Security Symposium 2025, arXiv:2402.07867, version 3, 13 August 2024 (first version 12 February 2024), viewed 8 November 2026. https://arxiv.org/abs/2402.07867
  7. Poisoning Retrieval Corpora by Injecting Adversarial Passages. Zexuan Zhong, Ziqing Huang, Alexander Wettig and Danqi Chen, EMNLP 2023, arXiv:2310.19156, 29 October 2023, viewed 8 November 2026. https://arxiv.org/abs/2310.19156
  8. BadRAG: Identifying Vulnerabilities in Retrieval Augmented Generation of Large Language Models. Jiaqi Xue, Mengxin Zheng, Yebowen Hu and others, arXiv:2406.00083, version 3, 29 September 2026 (first version 3 June 2024), viewed 8 November 2026. https://arxiv.org/abs/2406.00083
  9. Phantom: General Backdoor Attacks on Retrieval Augmented Language Generation. Harsh Chaudhari, Giorgio Severi, John Abascal and others, arXiv:2405.20485, version 3, 1 October 2025 (first version 30 May 2024), viewed 8 November 2026. https://arxiv.org/abs/2405.20485
  10. Machine Against the RAG: Jamming Retrieval-Augmented Generation with Blocker Documents. Avital Shafran, Roei Schuster and Vitaly Shmatikov, USENIX Security Symposium 2025, arXiv:2406.05870, version 4, 10 March 2025 (first version 9 June 2024), viewed 8 November 2026. https://arxiv.org/abs/2406.05870
  11. AgentPoison: Red-teaming LLM Agents via Poisoning Memory or Knowledge Bases. Zhaorun Chen, Zhen Xiang, Chaowei Xiao, Dawn Song and Bo Li, NeurIPS 2024, arXiv:2407.12784, 17 July 2024, viewed 8 November 2026. https://arxiv.org/abs/2407.12784
  12. Memory Injection Attacks on LLM Agents via Query-Only Interaction. Shen Dong, Shaochen Xu, Pengfei He and others, arXiv:2503.03704, version 5, 12 February 2026 (first version 5 March 2025), viewed 8 November 2026. https://arxiv.org/abs/2503.03704
  13. Agent Security Bench (ASB): Formalizing and Benchmarking Attacks and Defenses in LLM-based Agents. Hanrong Zhang, Jingyuan Huang, Kai Mei and others, ICLR 2025, arXiv:2410.02644, version 4, 30 May 2025 (first version 3 October 2024), viewed 8 November 2026. https://arxiv.org/abs/2410.02644
  14. Hidden in Memory: Sleeper Memory Poisoning in LLM Agents. Sidharth Pulipaka, Stanislau Hlebik, Leonidas Raghav and others, arXiv:2605.15338, version 2, 18 May 2026 (first version 14 May 2026), viewed 8 November 2026. https://arxiv.org/abs/2605.15338
  15. Utility Under Attack: Agent Memory Poisoning and the Limits of Content Screening and Provenance Ranking. Arulnidhi Karunanidhi, arXiv:2608.21230, 21 August 2026, viewed 8 November 2026. https://arxiv.org/abs/2608.21230
  16. ConfusedPilot: Confused Deputy Risks in RAG-based LLMs. Ayush RoyChowdhury, Mulong Luo, Prateek Sahu and others, arXiv:2408.04870, version 5, 23 October 2024 (first version 9 August 2024), viewed 8 November 2026. https://arxiv.org/abs/2408.04870
  17. Benchmarking Poisoning Attacks against Retrieval-Augmented Generation. Baolei Zhang, Haoran Xin, Jiatong Li and others, arXiv:2505.18543, 24 May 2025, viewed 8 November 2026. https://arxiv.org/abs/2505.18543
  18. Certifiably Robust RAG against Retrieval Corruption. Chong Xiang, Tong Wu, Zexuan Zhong and others, arXiv:2405.15556, version 2, 1 April 2026 (first version 24 May 2024), viewed 8 November 2026. https://arxiv.org/abs/2405.15556
  19. Spyware Injection Into Your ChatGPT's Long-Term Memory (SpAIware). Johann Rehberger, Embrace The Red, 20 September 2024, viewed 8 November 2026. https://embracethered.com/blog/posts/2024/chatgpt-macos-app-persistent-data-exfiltration/
  20. Hacking Gemini's Memory with Prompt Injection and Delayed Tool Invocation. Johann Rehberger, Embrace The Red, 10 February 2025, viewed 8 November 2026. https://embracethered.com/blog/posts/2025/gemini-memory-persistence-prompt-injection/
  21. Manipulating AI memory for profit: The rise of AI Recommendation Poisoning. Microsoft Defender Security Research Team and Noam Kochavi, Microsoft Security Blog, 10 February 2026, viewed 8 November 2026. https://www.microsoft.com/en-us/security/blog/2026/02/10/ai-recommendation-poisoning/
  22. Invitation Is All You Need! Promptware Attacks Against LLM-Powered Assistants in Production Are Practical and Dangerous. Ben Nassi, Stav Cohen and Or Yair, arXiv:2508.12175, 16 August 2025, viewed 8 November 2026. https://arxiv.org/abs/2508.12175
  23. Data Exfiltration from Slack AI via indirect prompt injection. PromptArmor, 20 August 2024, viewed 8 November 2026. https://promptarmor.substack.com/p/data-exfiltration-from-slack-ai-via
  24. Hacker plants false memories in ChatGPT to steal user data in perpetuity. Dan Goodin, Ars Technica, 24 September 2024, viewed 8 November 2026. https://arstechnica.com/security/2024/09/false-memories-planted-in-chatgpt-give-hacker-persistent-exfiltration-channel/

Notices

Superintelligence (SI) outputs can be wrong. Important decisions should include human review.

Test your agent before it holds real access.

Send us the agents, the tools and data they reach, where they run and what you want tested.

Test an agent