Security proxy for agent and LLM traffic: isolates keys, filters what leaves, keeps access reliable
The controlled plugin stops controlled-information markings and identifier values from leaving in an outbound request. It checks each request body for banner markings and for identifiers next to their own label. In block mode a request that holds one is rejected before any key is used. In report mode the request goes through and the finding is logged.
It is a safeguard that catches common markings. It does not prove a request is free of controlled data. Read What it does not cover before relying on it.
Compiled in by the default plugin-controlled feature; inactive until a [plugins.controlled] table exists. The earlier name gov still works as a table name, a reiki scan plugin and a feature, and will be removed in a later major version.
[plugins.controlled]
mode = "report" # "block" or "report"; required
# kinds = ["cui", "ein"] # default: cui, classification, dissemination
# upstreams = ["zen", "openrouter"] # default: all upstreams
| Key | Default | Meaning |
|---|---|---|
mode |
required | block rejects a request that holds a marking or identifier. report logs it and lets the request through. |
kinds |
cui, classification, dissemination |
The kinds to look for. |
upstreams |
all | Check only requests to these upstreams. A request to any other upstream is not checked. |
Start in report, read the log for false positives, then switch to block.
| Kind | Default | Matches |
|---|---|---|
cui |
on | An upper-case CUI banner: the whole line, ignoring surrounding whitespace and Markdown punctuation such as * or -; a line that starts with CUI// and a caveat marker such as CUI//SP-CTI; or a portion marking such as (CUI) at the start of a paragraph. A mention in prose, in quotes or in a JSON string is not a banner. |
classification |
on | TOP SECRET, SECRET or CONFIDENTIAL followed immediately by a // caveat chain, such as TOP SECRET//SI//NOFORN or SECRET//REL TO USA, GBR. A bare level is not reported. |
dissemination |
on | NOFORN or ORCON in the same banner shape as cui: alone on a line, as a // segment of a banner such as SECRET//NOFORN or TOP SECRET//SI//ORCON/NOFORN, or in a portion marking at the start of a paragraph. A mention in prose, in quotes or in a JSON string is not a banner. |
ein |
off | Two digits, a hyphen and seven digits after ein or employer identification number. No checksum; the label is the only gate. |
itin |
off | 9XX-XX-XXXX after itin or individual taxpayer identification number, with the historical group range 70-88, 90-92 or 94-99. |
cage |
off | Five characters from the CAGE alphabet (no I, O, Q or S) after cage or cage code. |
uei |
off | Twelve characters from the UEI alphabet (no I, O, Q or S) after uei or unique entity id. |
edipi |
off | Ten digits, not starting with zero, after edipi, dod id or dod_id. |
eccn |
off | A five-character export control number such as 5A002 after eccn, with an optional dot suffix. |
The keyword-bound kinds are off by default because their shapes alone collide with ordinary numbers and codes. Turn them on for a corpus that carries contracts or export paperwork.
Run reiki scan over sample data to see what this plugin flags before you choose a mode.
cui x1, dissemination x1, and never a value.422. A body with a Content-Encoding other than identity, or a body that is not valid UTF-8, cannot be read, so block mode rejects it with 415 and report mode logs that it was not checked. Content-Encoding: identity is a no-op and is checked as if the header were absent.phi and finance and before placeholders in the default build, so it sees the original request.SECRET, CONFIDENTIAL, EAR, ITAR, FCI, CTI, CMMC and FOUO are not detected on their own, because they are ordinary prose and code. A classification level is reported only with a // caveat chain.CUI, NOFORN and ORCON are reported only in banner or portion-marking shape. A mention in a sentence, in quotes or as a JSON string value is not reported, even when upper-case.ein, itin, cage, uei, edipi and eccn are reported only next to their own label. A bare number or code is not reported, and a label that appears after the value is not enough.block mode unusable.* lets data leave without being checked.