Secure RAG

Agents find the answer. Real values stay masked.

Secure RAG in GPTGuard masks sensitive data before indexing and applies your access policy at retrieval. You skip building the RAG stack yourself.

SOC 2 Type II · ISO 27001 · HIPAA, BAA available

Which claims need a follow-up this week?

Found in claim-notes.pdfcall-log.docxsla-policy.pdf

Trusted by regulated enterprises & agentic platforms
Inovalon
Automation Anywhere
Citrix
Bank Of Muscat Logo
Dell
Case study result

How an insurer ran LLMs on claims notes with PHI masked

$10M+

Projected first-year savings at the insurer

$200B

Yearly US cost of the overbilling it targeted

5,000+

Live enterprise tenants at Automation Anywhere

Why RAG security breaks after chunking

A company connects an assistant to its shared drive. An analyst asks a routine question, and the answer quotes a compensation file the analyst can’t open.

The permissions stayed on the file. They did not follow the chunks.

Permissions stay on the source file.

Once a document is chunked, embedded and retrieved, source rules often stop applying. RAG needs its own controls at retrieval.

Sensitive values reach the index.

Documents hold PII, PHI, contracts and pricing. Without protection, those values land in the index, the retrieved context and the response.

The stack takes months to build.

Ingestion, chunking, embedding, vector search, retrieval logic and agent APIs all come before the first secure answer.

How Secure RAG works, in five steps

Follow one claim note from upload to agent. In standard RAG, real values reach the model. In Secure RAG, everything after step 2 runs on tokens.

Real valuesTokens

What your team does

Same question, a different answer for each reader

You define who can see what. At retrieval, Protecto applies that policy for the user, the agent and the task.

The model reads tokens. Each reader sees the real values they are allowed to see, and the rest stay masked.

“What changes for the claims lead in March?”

What you would otherwise build

A vector database covers part of one row. Secure RAG runs all six as one system, so your team can start on the agent.

What secure RAG needsIf you build itIn Secure RAG
Document ingestionParsers, upload jobs and sync code for each sourceUpload files, use the RAG Document API or sync SharePoint, deletions included
Sensitive data detectionTune a detection model and maintain rules for your own IDs50+ entity types across PII, PHI and PCI, plus custom entities
Context-preserving maskingRedaction that removes what search and the model needThe same value always gets the same token, and the surrounding text stays
Indexing and retrievalChunking, embeddings and vector search, then tuning for masked textBuilt in, with retrieval designed for protected content
Access controlCarry permissions onto every chunk and keep them currentContext-Based Access Control (CBAC), document categories and user groups
Audit and unmaskingYour own logging, approval and reveal workflowEvent logs for each data action, with real values revealed by role

Fits the agents you already run

Your agent asks for context and gets masked passages back. It keeps its framework, its tools and its model.

REST APIs and MCP

Upload documents and retrieve relevant passages through the RAG Document API. Protecto also covers your agent’s MCP tool calls.

Any LLM

Protecto sits in front of the model. Use the provider you already have, and it receives masked context.

Your deployment

Run it as SaaS, on-prem, in a private cloud or air-gapped. Audit logs come with every option.

Chat for your staff

GPTGuard adds a secure chat interface on the same protected documents. Explore GPTGuard →

How an insurer searched clinical notes with PHI masked

The team wanted LLMs to compare clinical notes with billing codes and flag overbilling. Every record held PHI.

01

Masked before ingestion

Protecto scanned the clinical notes and masked PHI before they entered the pipeline.

02

Searched on masked notes

The masked notes were vectorized and stored. LLMs ran similarity searches on them to flag billing discrepancies.

03

Unmasked only for review

Fraud analysts reached original values through a secure unmask workflow when a case needed identifiable records.

“Protecto enabled us to deliver data security, privacy, and compliance for our AI features at scale across 5,000+ enterprise clients, strengthening customer trust in our AI automation solutions.”

SS
Steve Shah
SVP Product, Automation Anywhere
Security & compliance

Built for regulated data at enterprise scale.

Protecto combines data protection, audit logs, and ready-to-use policies for regulated data, whether deployed as SaaS, on-prem, in a private cloud, or air-gapped.

SOC 2 Type II

Audited controls

ISO 27001

Certified ISMS

HIPAA

BAA available

GDPR

EU data ready

DPDP

India privacy law

CCPA / CPRA

US privacy
Independently verified to outperform AWS Comprehend and Microsoft Presidio · audit logs on every scan, mask, and unmask.

Go deeper on secure RAG

Data Protection Architecture For Agentic Ai Whitepaper Cover
Whitepaper · 14 pages

Data Protection Architecture for Agentic AI

A reference architecture, with a section on files, RAG and embedding inputs, and an evaluation checklist for your review.

Questions about secure RAG

What is secure RAG?

Secure RAG is retrieval augmented generation with data protection at each step. Sensitive data is masked before indexing, access policy applies at retrieval, and each action is logged. Standard RAG copies documents into an index, where source permissions often stop applying.

Secure RAG is the document retrieval layer in GPTGuard. Agents and applications use it through REST APIs. GPTGuard adds a secure chat interface for your staff on the same protected documents.

It can when placeholders carry no meaning. Protecto gives each value a consistent token and leaves the surrounding text in place, so search and the model still have the context they need. Retrieval is designed for protected content.

You define which documents, categories, entities and context each user or agent may see. Your application passes that context with an auth key, and Protecto applies it at retrieval. Restricted values stay masked for that reader.

Yes, by policy. Each person sees the real values they are allowed to see, and the rest stay masked. Each reveal is logged.

Yes. Protecto covers your agent’s MCP tool calls as well as the context it retrieves.

You can upload files, send documents through the RAG Document API or sync from SharePoint, including on-premises SharePoint. Deletions in SharePoint carry over, so removed files stop being searchable.

Yes. GPTGuard connects to Active Directory and Okta and supports SSO. When your own agent calls the API, your application passes each user’s role or identity with the request.

As SaaS, on-premises, in a private cloud or air-gapped. You can use any LLM provider. With on-premises or private cloud deployment, your documents are processed in your environment.

No. DLP keeps guarding the channels it covers. Secure RAG covers the documents and context flowing to your models and agents, and works alongside DLP.

See Secure RAG on your documents

Bring a sample, with test data if you prefer. In 30 minutes, we will show you what each reader and agent gets back.

Data Protection Architecture for Agentic AI whitepaper cover
Technical whitepaper

Data Protection Architecture for Agentic AI

A reference architecture for protecting sensitive data across agent workflows, for architects and AI platform engineers.

By submitting you agree to Protecto’s privacy policy.

Cover of the guide Protect Sensitive Data Without Breaking AI Workflows
Technical guide

Protect sensitive data without breaking AI workflows

A practical guide to privacy controls for AI assistants, RAG, and agents. One workflow traced from request to CRM update, with what each destination may see.

By submitting you agree to Protecto’s privacy policy.

The AI Data Security Readiness Gap report cover
Research report

The AI Data Security Readiness Gap

What current industry research shows about where AI data controls fall behind adoption, with a five-question readiness framework.

By submitting you agree to Protecto’s privacy policy.

New: run any AI model without exposing real values.
See how it works