arXiv(opens in a new tab)cs.CRAug 2026Cited by 1 paper on PaperVantage

Manuscript Offprint

arXiv:2608.28389

CamoDocs: A Poisoning Attack Against Retrieval-Augmented Language Models Using Camouflaged Documents

Jaewon Jung, Haizhong Zheng, Hongsun Jang, Jaeyong Song, Beidi Chen, Jinho Lee

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

Retrieval-augmented generation (RAG) augments LLMs with external documents, but public or user-editable sources expose RAG systems to data poisoning: attackers can inject malicious documents to steer outputs toward targeted answers. Existing poisoning attacks often rely on query inclusion, inserting the target query into poisoned documents to improve retrieval; however, this creates lexical and embedding-space artifacts that make them easy to filter. We propose CamoDocs, a poisoning attack that avoids direct query inclusion by camouflaging adversarial documents among benign content. CamoDocs chunks synthesized benign and adversarial drafts, replaces selected tokens in benign chunks with dispersion tokens that spread poisoned-document embeddings, and applies coherence filtering to limit readability degradation. Across seven RAG defenses, three open-weight LLMs, and three benchmarks, CamoDocs achieves strong average ASR while avoiding query-overlap artifacts exploited by simple query detection. It also remains effective against proprietary models, achieving average ASRs of 61.80% on GPT-5.4-mini and 55.09% on Claude-Haiku-4.5. Finally, we show that erasure-heavy clustering defenses such as TrustRAG can reduce ASR, but only with substantial utility drops on retrieval-dependent benchmarks such as NeoQA. Code is available at https://github.com/jaewonalive/CamoDocs.

1 Introduction

Retrieval-augmented generation (RAG) (Xu et al., 2024; Lin et al., 2024; Wei et al., 2025; Ram et al., 2023) enables pretrained language models (PLMs) to access up-to-date external knowledge beyond their parametric knowledge cutoff (Lewis et al., 2020; Guu et al., 2020; Borgeaud et al., 2022) and reduces hallucinations by grounding generation in retrieved evidence (Shuster et al., 2021; Ji et al., 2023). However, because RAG relies on

Target: "Who is the CEO of OpenAI?"

Figure

Figure 1: Overview of CamoDocs. Unlike query-inclusion attacks that are easily filtered, CamoDocs injects dispersion tokens to evade RAG defenses and induce the target incorrect answer.

documents collected from the web (Thakur et al., 2021; Soboroff et al., 2018; Voorhees et al., 2021) or third-party knowledge bases (Voyage AI, 2026; Pinecone, 2026), attackers can poison these sources to steer the victim LLM toward a targeted incorrect answer. Understanding such poisoning attacks is critical for high-stakes applications (Loukas et al., 2023; Al Ghadban et al., 2023; Wang et al., 2024; Maqueda et al., 2018; Chen et al., 2024b).

As illustrated in Figure 1 (left), existing attacks (Zou et al., 2025; Zhang et al., 2025a; Liu et al., 2023) poison documents while including the target query to improve retrieval (hereafter called query inclusion). This query inclusion causes poisoned documents to cluster near the query embedding, and recent defenses such as TrustRAG (Zhou et al., 2025) leverage these characteristics to filter anomalously tight clusters and remove documents.

that conflict with the model’s internal knowledge of the query. Additionally, as query inclusion makes the adversarial documents explicitly contain the target query, simple query-detection defenses can be effective (Section 4.2).

However, these defenses rely on subsequent signals from query inclusion. To expose this weakness in existing defenses, we propose CamoDocs, a poisoning attack that does not rely on direct query inclusion. Instead, it generates benign and adversarial drafts with a synthesizer LLM, chunks them into sub-documents, and uses a surrogate encoder to replace selected tokens in benign sub-documents with dispersion tokens, as depicted in Figure 1 (right). These tokens disperse poisoned-document embeddings, preventing them from forming a compact malicious cluster. CamoDocs further applies coherence filtering to reduce readability degradation and merges the optimized benign sub-documents with adversarial sub-documents to form the final poisoned documents.

This paper makes the following contributions:

• We show that existing RAG poisoning attacks are defensible because they leave lexical and geometric artifacts: they include the target query and form compact embedding clusters.

• We show that erasure-heavy clustering-based defenses such as TrustRAG reduce RAG utility by filtering retrieved evidence, especially when the LLM must rely on external documents rather than parametric knowledge.

• We introduce CamoDocs, a gradient-guided poisoning attack that avoids query inclusion and disperses poisoned-document embeddings, achieving attack success across seven defenses, three open-weight models and two proprietary models.

References (74)