Skip to main content

Policy controls catalog

This page lists every policy control that the gateway runs, grouped by the phase in which it runs. Find the control for the result you need, then open its page for the settings and a test. A control runs only when it is in the applicable policies.chain.

New to policies? Start with the Policy configuration overview.

Select controls by outcome​

OutcomeStart withAdd when necessary
Block prompt attacksprompt-injectionembedding-detector for similarity signals
Remove personal identifierspii-detectorhipaa-phi-detector for more identifier patterns
Protect organization datadlp-filterdata-routing-policy to limit eligible providers
Control agent toolstool-validationtool-security, tool-budget, and agent-firewall
Control output quality or evidencequality-scorercitation-verifier and human-oversight
Change prompts or responsesrequest-rewriterresponse-rewriter for non-streaming output
Add compliance text controlsCompliance policy configurationOne compliance control at a time, after you read its limits
Record an audit markeraudit-loggerEvents and Trail for evidence, storage, and integrity

Controls with similar names do different work. For example, tool-budget checks the requested output-token cap and recorded per-session tool-token totals against each tool limit. It does not measure financial cost. audit-logger adds an allow-only marker and does not configure retention.

In the tables below, Families shows the request families that a control accepts:

  • All: Chat Completions, Completions, Responses, Messages, Embeddings, Audio, and Moderation
  • Text: Chat Completions, Completions, Responses, and Messages
  • Tools: Chat Completions, Responses, and Messages

The gateway evaluates the chain on all eight request families. On the embeddings, audio, moderation, and legacy completions routes, only the input phase runs. Output phase controls do not apply to these routes. See Runtime request families.

Input phase controls​

These controls examine the request before the gateway forwards it.

ControlWhat it doesFamilies
prompt-injectionDetects jailbreak and prompt-injection signalsText
pii-detectorRedacts or blocks personal identifiers in the request, and redacts them in the buffered responseAll
hipaa-phi-detectorAdds HIPAA-style PHI checks to the shared redaction pipelineText
dlp-filterApplies pattern-based data loss preventionAll
safety-filterBlocks or escalates configured dangerous termsText
rbacEnforces role, identity, and data-sensitivity access rulesAll
cjis-modeEnforces CJIS-style constraints on the authenticated identityAll
student-privacyDetects student-record markers and replaces student-ID phrasesText
case-privacyDetects built-in case-number patternsText
itar-ear-filterBlocks export-control reference termsText
entity-list-filterMatches denied or watch-listed entitiesText
dual-use-filterDetects dual-use and sensitive capability signalsText
data-routing-policyLimits the provider targets that can receive the requestAll
bot-detectorFlags matching fingerprints or near-identical prompts on one gatewayAll
request-rewriterChanges selected request text fields before forwardingText
gdpr-complianceBlocks a request without the consent header when consent_required is setAll
audit-loggerAdds an allow-only audit marker to the decisionAll

Input and output phase controls​

These controls examine request fields or tool data. Some also check responses. A stage override does not add support for a response format that the control does not read.

ControlWhat it doesFamilies
language-validatorChecks input, output, or both against allowed languagesText
agent-firewallAllows or denies tool use and enforces action and transaction limitsTools
embedding-detectorCompares text with references by word overlap or configured embeddingsAll
external-moderationSends content to a third-party moderation serviceText
content-extractorFetches content from URLs in request messages, within host and size limitsText
document-analyzerExamines documents in the request JSONText
code-sanitizerMatches message text against built-in and custom code-safety patternsText
tool-validationValidates declared tool names, schema syntax, and structured tool-call argumentsTools
tool-securityBlocks unsafe tool definitions in the requestTools
tool-budgetChecks output-token caps and recorded session use against tool limitsTools

Output phase controls​

These controls examine Chat Completions, Responses, and Messages output. Legacy Completions has input-stage coverage only. Streaming controls can hold output until evaluation completes. flagged-review cannot enforce streaming and is rejected for that use. See Streaming and SSE.

ControlWhat it doesFamilies
quality-scorerScores output quality and blocks or replaces output below the thresholdText
human-oversightReturns an escalated result instead of the assistant contentText
flagged-reviewReviews each response with a model, or escalates it without oneText
citation-verifierChecks that the request context supports the citations in the outputText
mnpi-filterBlocks output that contains configured MNPI phrasesText
financial-complianceApplies finance-oriented output controlsText
healthcare-complianceEnforces medical blocked patterns and disclaimersText
legal-privilegeBlocks output that contains privilege markersText
upl-filterMatches legal-advice phrases and adds a disclaimer or blocks the responseText
bias-monitorEscalates when the HR bias score reaches the thresholdText
response-rewriterApplies deterministic text rules to the responseText

Reporting-only controls​

eu-ai-act exists for compliance reports only. Lint accepts it in policies.chain, but the gateway then blocks every request with reason code policy.reporting_only. Put its settings in policy.eu-ai-act and generate the report with POST /verdictan/compliance/report.

How the chain selects controls​

policies.chain decides which controls run. policy.<kind> only holds their settings. A settings block without a chain entry does nothing:

policies:
  chain:
    - prompt-injection
policy:
  prompt-injection: {}

A route chain, a when condition, or targeting can also include or remove a control for a request. The output phase controls ignore when, so use routes for them. See Conditional chain configuration.

When a control returns block or escalate, the rest of that phase does not run. Put audit-logger first if blocked requests must also have its marker.

Lint checks structure. It does not prove that a control runs for live traffic. The active chain, route, conditions, and gateway version decide that.

Starter configurations​

Save one of these as policy-config.yaml in a new test directory. Each passes verdictan policy lint. Add your provider settings before you send live requests.

PII redaction with audit logging​

policy-config.yaml
pack:
  name: pii-redaction
  version: "1.0.0"
  enabled: true

policies:
  chain:
    - audit-logger
    - pii-detector

policy:
  pii-detector:
    action: redact
    redaction:
      marker_format: label
      include_metadata: true
  audit-logger: {}

Validate a chain​

  1. Lint the file. A valid file exits with code 0:

    verdictan policy lint --file policy-config.yaml
  2. Add the offline test cases from the page of each control, and run verdictan policy test --json.

  3. Apply the file to a test agent with the config-first workflow.

  4. Send a usual request and a request that matches the control. Examine the nested policy results with verdictan events tail --since 5m --json.

For redaction, check the forwarded or returned text. A redact verdict without replacement targets does not prove that sensitive content was removed.

Limits and failure behavior​

  • The gateway does not load a config with an unknown control in policies.chain or policy. verdictan policy lint reports unknown policy kind first.
  • human-oversight supports only action: escalate. The gateway rejects removed fields such as require_human_for and timeout_seconds.
  • language-validator supports apply_to: input, output, or both. Output language checks hold streamed output until it can be checked. Set the field explicitly; see Language validator.
  • Output controls read the buffered response. A streaming request through flagged-review fails with streaming.policy_cannot_enforce.
  • gdpr-compliance and eu-ai-act have no control page of their own. Compliance policy configuration describes them.
  • These controls do not make you compliant on their own. You still own legal review, operating processes, and provider governance.

Troubleshooting​

ProblemLikely causeWhat to examine
The file lints but the control does not runThe chain does not include it, or a route, when, or targeting removes itThe applied global or route chain and the request context
An output control works only for some clientsThe response structure or the streaming mode is differentThe request family, the stream value, and the supported response paths
A later result is missingAn earlier control stopped the phaseThe chain order and the block or escalation reason code
Pack tests pass but live requests failThe test runner does not simulate every gateway handler and transportThe same request through a test gateway and provider
The decision reason code is ok after an allowA nested allow reason does not replace the envelope reasonThe policy_results array and the decision envelope

Next steps​