docs(features): document the egress filter's secret, PII and PHI controls - #844
Merged
Conversation
…rols The Egress Filter page existed but carried no screenshots and covered only part of the surface. Expand it to the whole feature and illustrate it from the product: - Scope of "outbound": prior turns, KB documents, tool output, agent scratchpad and the system prompt, not just what a user typed. - The built-in secret rule corpus, and the high-entropy detector that dominates detect-mode events. - PII / PHI scrubbing end to end: reversible tokenisation and response rehydration, per-category detection, what is never scrubbed (IPs) and what is never restored (credentials). - The per-message evidence trail: the chips on an answer and the detail view behind them, with audit IDs for log correlation. - The EGRESSFILTER_REVEAL_VALUES feature flag and why it belongs in a test environment only. - Permissions (egressfilter:Read / :Write, tenant-scoped). Also document the Egress secret filter (DLP) control on Gateway → Data & privacy, which applies the same detector to gateway-proxied traffic, and link the feature from the AI index and the Security page. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018kNH7US6EMJeysNtg6dKza Signed-off-by: Piyush Bhavsar <iampiyush.bhavsar@gmail.com>
There was a problem hiding this comment.
Code Review
This pull request significantly expands and updates the documentation for the AI Gateway, Egress Filter, and security features, adding detailed explanations of data privacy, egress secret filtering, PII/PHI scrubbing, and audit capabilities. The review feedback focuses on improving terminology consistency across the documentation, specifically suggesting capitalizing 'stable ID', correcting 'Egressfilter' to 'Egress Filter', and aligning the policy modes to 'detect, enforce, or redact'.
mayankpande88
previously approved these changes
Sep 7, 2026
- "stable id" -> "stable ID", matching "audit ID" elsewhere on the page. - security.md now names the actual mode names (detect, enforce, redact) instead of paraphrasing them as record/block/mask. Left "Egressfilter Reveal Values" as-is: that is the verbatim label the feature flag carries in Tenant Settings, so renaming it would stop readers finding it in the UI. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018kNH7US6EMJeysNtg6dKza Signed-off-by: Piyush Bhavsar <iampiyush.bhavsar@gmail.com>
The "Last changed by" line carried an internal user UUID from the dev tenant. Reshot with an all-zero example UUID in its place, so the line keeps the shape a reader will see without publishing a real identifier. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018kNH7US6EMJeysNtg6dKza Signed-off-by: Piyush Bhavsar <iampiyush.bhavsar@gmail.com>
Kankshit-02
approved these changes
Sep 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The Egress Filter page existed but carried no screenshots and covered only part of the surface — the PII/PHI detector, the per-message evidence trail, the permission model and the raw-value reveal flag were all undocumented. This expands it to the whole feature and illustrates it from the product.
features/ai/egress-filter.md— rewritten:high-entropy-bloband a warning that it will dominate detect-mode events.EMAIL/PHONE, NER forPERSON/LOCATION), what is never scrubbed (IPs, deliberately — they are investigation signal) and what is never restored (credentials, redacted irreversibly even when tokenisation is on).egress-…/scrub-…audit IDs for log correlation.EGRESSFILTER_REVEAL_VALUES— documented with a:::dangernote explaining that it writes matched secrets and personal data unmasked into a persistent table, and that a tenant running PII Enforce for HIPAA/GDPR is not compliant with it on.egressfilter:Read/egressfilter:Write, tenant-scoped with no per-account dimension.features/ai/ai-gateway.md— the Egress secret filter (DLP) control on Data & privacy was undocumented; it applies the same detector to gateway-proxied traffic. Also notes the retention/visibility limits on captured bodies.features/ai/index.md,features/security.md— one-line pointers so the feature is reachable from both entry pages. Security is the page a compliance reviewer reads, and it said nothing about what leaves for a model provider.Type of change
Checklist
npm run buildlocally and the site builds without errorsnpm run lintlocally and lint passesgit commit -s)onBrokenLinksisthrow, so a clean build confirms every internal link resolves.Screenshots (if visual changes)
Seven new screenshots under
features/ai/img/, taken from the dev instance: the two halves of the Egress Filter tab, the custom-pattern dialog, the chips on a NuBi answer, both halves of the detail modal, and the gateway Data & privacy tab.Additional notes
Two screenshots are edited, both to keep dev-tenant identifiers out of public docs. Nothing else in any image is altered.
egress-filter-details-secrets.pngEGRESSFILTER_REVEAL_VALUESenabled, so the detail modal renders matched values verbatim — including a GCP-shaped key that arrived through the agent scratchpad rather than the test prompt. Masked with an opaque bar; the pixels are overwritten, not blurred.gateway-data-privacy.pngEverything else visible in the screenshots is synthetic: the AWS key is invented, and the phone numbers are in the reserved 555-01XX fictional range.
Two consequences worth a reviewer's attention:
raw values shown — testing modebadge. The page calls this out directly under the:::dangernote. If we would rather ship the default view, someone needs to turn the flag off on the dev tenant and the two images can be reshot.llm_conversation_messages.metadataon dev and rendering for anyone who opens that conversation.Deliberately left out: the platform-level
LLM_SERVER_EGRESSFILTER_*environment variables. No other page in the docs carriesLLM_SERVER_*configuration, so the page says "platform level" and stops there. Worth adding as a self-hosted operator section if that gap comes up.🤖 Generated with Claude Code
https://claude.ai/code/session_018kNH7US6EMJeysNtg6dKza