Prevented is Not Protected: What Attack Success Rate Hides about RAG
Organizations: University of Nevada, Las Vegas
Abstract
Retrieval-Augmented Generation (RAG) is vulnerable to knowledge poisoning, where adversaries manipulate retrieved evidence to influence model outputs. Existing defenses are primarily evaluated using attack success rate (ASR), which obscures defense-induced failures and the mechanisms behind apparent attack prevention. To address this issue, this work introduces Aligned RAG Evaluation, a matched-query protocol that jointly examines clean and poisoned responses, with and without defense. By combining matched conditions analysis, LLM-judge endorsement, and retrieval dependence controls, the proposed framework distinguishes prevented from introduced failures, target mentions from LLM endorsement, and single-passage influence from evidence composition. Experiments on HotpotQA and Natural Questions reveal that existing defenses can introduce unexpected target-positive answers, although they can prevent some attacks, while evaluation criteria can also change defense rankings. Our findings expose critical blind spots in ASR-based evaluation and motivate a more comprehensive assessment of RAG poisoning defenses. The code and the evaluation artifact are available at https://github.com/chxhana/aligned-rag-eval.
Figures & tables
| Retrieval | No defense | Defense |
|---|---|---|
| Clean | ||
| Poisoned |
| Dataset | Pipeline | [95% CI] | [95% CI] | [95% CI] | |
| HotpotQA | KeywordAgg | 0 [ , 9] | [ , ] | [ , 3] | 1.000 |
| Prompt control | [ , ] | [ , ] | [ , ] | .029 | |
| TrustRAG | 0 [ , 13] | 12 [5, 21] | 12 [4, 22] | 1.000 | |
| NQ | KeywordAgg | 22 [15, 28] | 1 [0, 3] | 23 [16, 29] | |
| Prompt control | [ , 1] | [ , 2] | [ , 1] | .263 | |
| TrustRAG | 18 [10, 26] | 9 [6, 12] | 27 [18, 36] | .002 |
| Setting | vs. | Rates | Diff. | 95% CI | |
|---|---|---|---|---|---|
| HotpotQA, | KeywordAgg | 79 | 11–38 | [ , ] | |
| HotpotQA, | Prompt | 80 | 12–66 | [ , ] | |
| HotpotQA, | KeywordAgg | 79 | 10–71 | [ , ] | |
| HotpotQA, | Prompt | 76 | 11–93 | [ , ] | |
| NQ, | KeywordAgg | 77 | 9–23 | [ , ] | |
| NQ, | Prompt | 78 | 9–64 | [ , ] |
| HotpotQA | NQ | |||
| Poison budget | 1 | 5 | 1 | 5 |
| Poisoned positives | 60 | 96 | 64 | 92 |
| Newly induced | 46 | 79 | 62 | 90 |
| Injection-dependent | 45 | 74 | 60 | 87 |
| Single-passage sufficient | 57/60 | 96/96 | 60/64 | 91/92 |
| Victim | Clean | Poisoned | Single suff. | |
|---|---|---|---|---|
| Llama-3-8B | 1 | 17 | 60 | 57/60 |
| Llama-3.1-70B-AWQ | 1 | 8 | 57 | 54/57 |
| Llama-3-8B | 5 | 17 | 96 | 96/96 |
| Llama-3.1-70B-AWQ | 5 | 8 | 95 | 95/95 |
| Setting | Clean | Poisoned | New | Strict | Single suff. | Clean EM |
|---|---|---|---|---|---|---|
| Contriever / Llama-3-8B | 10 | 27 | 23 | 7 | 17/27 | 53 |
| BGE cosine512 / Llama-3-8B | 8 | 18 | 11 | 2 | 12/18 | 66 |
| Contriever / Llama-3.1-70B-AWQ | 8 | 18 | 16 | 0 | 14/18 | 111 |
Appendix figures & tables13 assets
Supplementary material from the paper’s appendix.
Appendix
| Dataset | Method | Ref. yes / resolved | Uncertain | Correct lost | Correct retained |
|---|---|---|---|---|---|
| HotpotQA | No defense | 87/120 | 80 | 0 | 87 |
| HotpotQA | KeywordAgg | 75/96 | 104 | 5 | 59 |
| HotpotQA | Prompt control | 74/104 | 96 | 5 | 65 |
| HotpotQA | TrustRAG | 29/53 | 147 | 5 | 20 |
| NQ | No defense | 92/134 | 66 | 0 | 92 |
| NQ | KeywordAgg | 71/123 | 77 | 17 | 56 |
| Data | Pipeline | Clean | ||
|---|---|---|---|---|
| Hotpot | KeywordAgg | 17 7 | 60 60 | 96 91 |
| Prompt | 17 4 | 60 72 | 96 94 | |
| TrustRAG | 17 29 | 60 60 | 96 32 | |
| NQ | KeywordAgg | 2 3 | 64 42 | 92 82 |
| Prompt | 2 1 | 64 70 | 92 92 | |
| TrustRAG | 2 11 | 64 46 | 92 14 |
| Data | Pipeline | [95% CI] | ||
|---|---|---|---|---|
| Hotpot | KeywordAgg | 5 [0, 11] | ||
| Prompt | 2 [ , 7] | |||
| TrustRAG | 64 [55, 73] | 12 | 76 | |
| NQ | KeywordAgg | 10 | 1 | 11 |
| Prompt | 0 | |||
| TrustRAG | 78 | 9 | 87 |
| Data | None | Key. | Prompt | Trust | |
|---|---|---|---|---|---|
| HotpotQA | 1 | 35/9 | 34/13 | 61/10 | 11/10 |
| HotpotQA | 5 | 77/10 | 58/17 | 76/19 | 9/6 |
| NQ | 1 | 42/11 | 20/13 | 55/13 | 7/11 |
| NQ | 5 | 59/25 | 47/13 | 65/29 | 2/9 |
| Label | Valid/Unc. | Overall | Decisive |
|---|---|---|---|
| Target | 95+(5 N/A) / 26 | 69/100, | 64/69, |
| Reference | 98 / 30 | 50/98, | 50/68, |
| Abstention | 99 / 28 | 67/99, | 67/71, |
| HotpotQA | NQ | |||||
| Metric (of 100) | (1,5) | (5,5) | (1,10) | (5,10) | (1,5) | (5,5) |
| Clean target | 17 | 17 | 15 | 15 | 2 | 2 |
| Poisoned target | 60 | 96 | 59 | 78 | 64 | 92 |
| Newly induced | 46 | 79 | 45 | 64 | 62 | 90 |
| injection-dependent | 45 | 74 | 44 | 62 | 60 | 87 |
| Strict newly induced | 1 | 0 | 1 | 2 | 0 | 0 |
| Defense | Hit /27 | Strict /7 | Added | Final |
|---|---|---|---|---|
| Graph scores (3) | 0 | 0 | 0 | 27 |
| Score minimum | 0 | 0 | 0 | 27 |
| Score gap | 10 | 2 | 0 | 17 |
| Score dispersion | 8 | 2 | 0 | 19 |
| KeywordAgg | 13 | 6 | 11 | 25 |
| Prompt control | 12 | 6 | 6 | 21 |
| Dataset | Threshold | Intercepted | |
|---|---|---|---|
| HotpotQA | 1 | 59/60 | |
| HotpotQA | 5 | 0/96 | |
| NQ | 1 | 32/64 | |
| NQ | 5 | 1/92 |
| Encoding | Gap hit ( ) | FPR |
|---|---|---|
| Dot128/512 | 59/60 0/96 | 1.0 |
| Dot512 | 65/66 0/95 | 1.0 |
| Cosine512 | 61/63 0/97 | 0.5 |
| Arm (base) | Pipeline | P/I | Final |
|---|---|---|---|
| Dot128/512 (60) | KeywordAgg | 15/15 | 60 |
| Prompt | 7/19 | 72 | |
| TrustRAG | 20/20 | 60 | |
| Dot512 (66) | KeywordAgg | 15/9 | 60 |
| Prompt | 8/14 | 72 | |
| TrustRAG | 21/10 | 55 |
RAG Poisoning Attacks
Retrieval-augmented generation (RAG) poisoning attacks manipulate retrieved knowledge to steer, degrade, or disrupt model outputs.
See all 78 papers