通过明否认正确答案来欺骗RAG系统,让大模型输出错误答案。
DenialRAG: Single-Document RAG Poisoning via Embedded Parametric Denial

- 在毒化文档中同时列出正确答案并直接否定,用攻击者控制的解释替代
- 对Mistral-7B系列模型攻击成功率最高,跨模型表现差异显著
- 揭示了不同模型对中毒机制的敏感性不同,防御效果不均衡
检索增强生成(RAG)系统易受语料库投毒攻击:攻击者只需向检索语料库中插入一段精心构造的文档,即可引导大语言模型(LLM)生成攻击者指定的错误答案。以往单文档攻击通常避免在毒化文本中明确提及并反驳正确答案。本文提出一种互补性设计——DenialRAG,该攻击在单一文档中显式指出正确答案、加以否认,并提供攻击者控制的解释以支持错误答案。通过将正确答案与伪造答案置于同一检索片段中,DenialRAG将矛盾直接嵌入生成器可见的上下文中。我们在三个开放域问答数据集上评估DenialRAG,对比四种已有单文档攻击方法,涵盖八种来自四个厂商的目标LLM及五种推理时防御机制。结果表明,攻击有效性高度依赖模型:DenialRAG在所有Mistral-7B数据集上取得最高攻击成功率(ASR),并在多个其他目标LLM上仍有效;而其他攻击在部分模型上占优。防御实验显示,各防御方法均能显著降低ASR,但保护效果不一,部分场景下仍残留显著攻击成功率。组件级与跨模型分析进一步确认,嵌入式否认是影响最大的测试组件,且不同中毒机制在各类模型中的失效速度各异。综合结果表明,RAG投毒风险无法仅由单一攻击家族或单一目标模型完全刻画。
原文摘要 · Abstract (English)
Retrieval-augmented generation (RAG) systems are vulnerable to corpus poisoning: an attacker who inserts a crafted document into the retrieval corpus can steer the underlying large language model (LLM) toward an attacker-chosen wrong answer. Prior single-document attacks typically avoid explicitly naming and refuting the correct answer inside the poisoned passage. In this paper, we examine a complementary design and propose \emph{DenialRAG}, a single-document poisoning attack that explicitly names the correct answer, denies it, and presents an attacker-controlled explanation for favoring the wrong answer. By placing both the correct answer and the corresponding poisoned answer inside the same retrieved passage, DenialRAG embeds the conflict directly into the context seen by the generator. We evaluate DenialRAG against four published single-document poisoning attacks across three open-domain question-answering datasets, eight target LLMs from four vendors, and five inference-time defenses. The results show that attack effectiveness is strongly model-dependent: DenialRAG achieves the highest attack success rate (ASR) on all three Mistral-7B datasets and remains effective on several other target LLMs, while other attacks dominate in some model regimes. Defense results show meaningful ASR reductions but non-uniform protection, with each defense leaving residual ASR in some settings. Component-level and cross-model analyses further identify the embedded denial as the most influential tested component and show that different poisoning mechanisms lose effectiveness at different rates across model groups. Together, these results show that RAG poisoning risk cannot be fully characterized by a single attack family or a single target model.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。