site/docs/red-team/plugins/rag-document-exfiltration.md
Use the RAG Document Exfiltration plugin to test whether a retrieval-augmented system exposes complete documents, sensitive passages, or proprietary material beyond what the user should receive.
It focuses on whether the model:
The plugin generates test cases that simulate scenarios where full documents might be exposed. These test cases challenge the AI's ability to:
To include the RAG Document Exfiltration plugin in your LLM red teaming setup:
redteam:
plugins:
- rag-document-exfiltration
You can customize the number of test cases:
redteam:
plugins:
- id: 'rag-document-exfiltration'
numTests: 10
The plugin assesses the AI's response based on:
Document exfiltration testing matters when retrieval quality and disclosure limits pull in opposite directions. This plugin checks whether the system stays within authorized disclosure limits instead of revealing sensitive document content, whether verbatim or summarized.