AI Penetration Testing · RAG Security
How secure is your
RAG system?
Your vector database is the blind spot of every LLM pentest. Document poisoning, indirect prompt injection, and retrieval manipulation attack where classic security tools don't look. We test RAG systems the way real attackers do.
Malicious content in the knowledge base
Insufficient access controls
Reconstruction of sensitive original data
Forcing attacker-controlled context
Injected instructions in context
Poisoned training data via RAG
A classic LLM pentest only covers the GENERATE layer.
- RAG attack layers
- 4
- Pentests conducted
- 500+
- Fixed-price offer
- 48h
- Subcontractors
- 0
Attack Vectors
The Four Main Attack Vectors on RAG Systems
A RAG system is more than an LLM. Every layer - ingestion, vector database, retrieval, generation - has its own attack surface that a classic LLM pentest does not cover.
Document Poisoning
An attacker injects malicious content into the knowledge base of your RAG system - via compromised data sources, manipulated document uploads, or poisoned public content that your system crawls. The LLM trusts the retrieved context and executes the embedded instructions.
Injected instructions in PDFs, Word documents, emails
Manipulation of crawled web content and RSS feeds
Compromise of third-party system interfaces (SharePoint, Confluence)
Long-term poisoning: attacks on future retrieval sessions
Vector Database Manipulation
Vector databases (Pinecone, Weaviate, Chroma, pgvector) are often insufficiently secured: missing access controls at namespace level, weak multi-tenancy isolation, and unencrypted embeddings enable unauthorized access to sensitive company data - or targeted manipulation of stored knowledge.
Insufficient namespace isolation in multi-tenant systems
Direct API manipulation without authentication
Reconstruction of sensitive texts from embeddings (model inversion)
Missing audit logs for retrieval operations
Retrieval Manipulation
The retrieval phase determines which context is passed to the LLM. Attackers manipulate search queries or embedding vectors to force attacker-controlled content into the context - thereby controlling the model's output behavior without requiring direct access to the model itself.
Query manipulation to force attacker-controlled documents
Adversarial embeddings with high cosine similarity to target queries
Re-ranking exploits in advanced RAG architectures
Context window flooding: displacing legitimate content
Indirect Prompt Injection
The most dangerous RAG attack: hidden instructions in retrieved documents are interpreted by the LLM as legitimate requests - without the actual user's knowledge. In RAG systems with agent capabilities, this can lead to remote code execution.
Hidden instructions in publicly accessible documents
Exfiltration of system context and other user data
Tool abuse in agent-based RAG systems (MCP, function calling)
Persistent manipulation across multiple conversation turns
Classic WAFs and input filters do not detect this attack.
Architecture
How a RAG system works - and where attacks target
Every phase of the RAG workflow has its own attack surface. Highlighted in red: positions we systematically test.
Document Ingestion
Crawl & ingest data sources
Embedding Generation
Text → Vectors
Vector Database
Pinecone · Weaviate · pgvector
Retrieval
Semantic search
LLM Generation
Context + Query → Response
Important: A classic LLM pentest tests only layer 05 (Generation) - what the user directly inputs. The four preceding layers of your RAG system remain untested.
Test Scope
What we test in your RAG system
Six specialized test categories - from the document ingestion process to final model behavior.
Document Poisoning & Data Poisoning
Testing all ingestion paths for susceptibility to poisoned documents: PDF, DOCX, HTML, Markdown, emails, API feeds. Testing validation and sanitization logic before ingestion into the vector database.
Vector Database Security
Access controls, namespace isolation, multi-tenancy separation, authentication and authorization at the API level. Testing for embedding extraction (model inversion) and unauthorized data access.
Indirect Prompt Injection
Systematic injection of instructions via all retrieval paths: documents, web content, emails, database entries. Testing for exfiltration of system context and user data, as well as tool abuse.
Retrieval Pipeline Testing
Adversarial queries and embedding manipulations to force attacker-controlled contexts. Testing of re-ranking mechanisms, HyDE weaknesses, and context window flooding attacks.
RAG Guardrail Assessment
Evaluation of protection layers against retrieval-based attacks: contextual guardrails, output grounding checks, hallucination detectors, and anomaly detection for unusual retrieval patterns.
Agentic RAG & Tool Security
For RAG systems with agent capabilities: tool abuse via indirect injection, privilege escalation through tool access, multi-step exploitation, and memory poisoning in persistent agents.
Methodology
Our approach to RAG security testing
1-2 days
Architecture Analysis & Threat Modeling
Capture of all RAG components: data sources, embedding models, vector database, retrieval strategy, connected LLMs, and agent capabilities. Threat modeling per MITRE ATLAS specifically for RAG architectures.
2-3 days
Data Sources & Ingestion Path Analysis
Identification of all ingestion paths: which documents, data sources, and feeds are processed? Where are validation gaps? Which paths are influenceable by external actors (public websites, emails, APIs)?
3-5 days
Document Poisoning & Injection Tests
Systematic injection of poisoned documents via all identified paths. Manual development of prompt injection payloads for indirect attacks, adapted to the specific system prompt and retrieval context of the target system.
2-3 days
Vector Database & Retrieval Tests
Testing vector database security: access controls, multi-tenancy, embedding extraction. Adversarial retrieval attacks: query manipulation, embedding poisoning, context window flooding.
2-3 days
Exploitation & Reporting
Confirmation of critical findings with proof-of-concept and quantified business impact. Technical report with CVSS scoring, compliance mapping (OWASP LLM Top 10, MITRE ATLAS, EU AI Act), and prioritized remediation roadmap.
Typical total duration: 10-15 days - depending on architectural complexity and number of data sources.
You receive a binding fixed-price offer within 48 hours.
Investment
Transparently calculated
Fixed-price offers within 48 hours. No hourly rates, no additional charges.
FOCUSED
RAG Security Test
Dedicated test of your RAG system
from EUR 10,000
- Document poisoning of all ingestion paths
- Vector database security testing
- Indirect prompt injection (all retrieval paths)
- Retrieval manipulation tests
- Guardrail assessment (contextual guardrails)
- Technical report + management summary
COMPREHENSIVE
AI Security Assessment
RAG + LLM + Agents - complete
from EUR 15,000
- Everything from the RAG security test
- LLM pentest (full OWASP Top 10 LLM)
- AI agent testing (tool abuse, privilege escalation)
- Agentic RAG security review
- Compliance mapping (EU AI Act, ISO 42001)
- Final presentation + remediation workshop
Also deploying an LLM chatbot or AI agent? View full AI penetration testing services →
Warum AWARE7
Was uns von anderen Anbietern unterscheidet
Reine Awareness-Plattformen testen keine Systeme. Reine Beratungskonzerne sind zu weit weg. AWARE7 verbindet beides: Wir hacken Ihre Infrastruktur und schulen Ihre Mitarbeiter - mittelstandsgerecht, persönlich, ohne Enterprise-Overhead.
Forschung und Lehre als Fundament
Rund 20% unseres Umsatzes stammen aus Forschungsprojekten für BSI und BMBF. Unsere Studien analysieren Millionen von Websites und Zehntausende Phishing-E-Mails - publiziert auf ACM- und Springer-Konferenzen. Drei unserer Führungskräfte sind gleichzeitig Professoren an deutschen Hochschulen.
Digitale Souveränität - keine Kompromisse
Alle Daten werden ausschließlich in Deutschland gespeichert und verarbeitet - ohne US-Cloud-Anbieter. Keine Freelancer, keine Subunternehmer in der Wertschöpfung. Alle Mitarbeiter sind sozialversicherungspflichtig angestellt und einheitlich rechtlich verpflichtet. Auf Anfrage VS-NfD-konform.
Festpreis in 24h - planbare Projektzeiträume
Innerhalb von 24 Stunden erhalten Sie ein verbindliches Festpreisangebot - kein Stundensatz-Risiko, keine Nachforderungen, keine Überraschungen. Durch eingespieltes Team und standardisierte Prozesse erhalten Sie einen klaren Zeitplan mit definiertem Starttermin und Endtermin.
Ihr fester Ansprechpartner - jederzeit erreichbar
Ein persönlicher Projektleiter begleitet Sie vom Erstgespräch bis zum Re-Test. Sie buchen Termine direkt bei Ihrem Ansprechpartner - keine Ticket-Systeme, kein Callcenter, kein Wechsel zwischen wechselnden Beratern. Kontinuität schafft Vertrauen.
Für wen sind wir der richtige Partner?
Mittelstand mit 50–2.000 MA
Unternehmen, die echte Security brauchen - ohne einen DAX-Konzern-Dienstleister zu bezahlen. Festpreis, klarer Scope, ein Ansprechpartner.
IT-Verantwortliche & CISOs
Die intern überzeugend argumentieren müssen - und dafür einen Bericht mit Vorstandssprache brauchen, nicht nur technische Findings.
Regulierte Branchen
KRITIS, Gesundheitswesen, Finanzdienstleister: NIS-2, ISO 27001, DORA - wir kennen die Anforderungen und liefern Nachweise, die Auditoren akzeptieren.
Mitwirkung an Industriestandards
OWASP · 2023
OWASP Top 10 for Large Language Models
Prof. Dr. Matteo Große-Kampmann als Contributor im Core-Team des international anerkannten OWASP LLM-Sicherheitsstandards.
BSI · Allianz für Cyber-Sicherheit
Management von Cyber-Risiken
Prof. Dr. Matteo Große-Kampmann als Mitwirkender des offiziellen BSI-Handbuchs für die Unternehmensleitung (dt. Version).
Frequently Asked Questions about RAG Security
Everything about vector database security, document poisoning, and RAG pentesting.
What is a RAG system?
What is document poisoning?
How secure are vector databases?
What is indirect prompt injection in RAG?
Which RAG architectures do you test?
What does a RAG security test cost?
How do I protect my RAG system?
Do I need a separate RAG test or is an LLM pentest sufficient?
Is a RAG security test relevant for the EU AI Act?
How secure is your RAG system really?
Our experts test vector databases, document poisoning, and indirect prompt injection - with a fixed-price commitment and audit-ready reporting.
Kostenlos · 30 Minuten · Unverbindlich