Available in
Marketplaces, most starred first
Tags
Add to README
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
By williansaezv2.3.1MITIn 1 marketplace
Keep personal data (LGPD/GDPR) out of the model. Redacts tool results with reversible pseudonyms, blocks prompts carrying PII, and logs every violation.
You run one by typing its /name in Claude Code.
1 caution to review before installing
A hook runs when Claude uses the Bash tool
Static checks of hooks, mods, MCP servers and commands. Not a security audit.
1 marketplace, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Executables (bin/) — files in this plugin's bin/ directory are added to the Bash tool's PATH while the plugin is enabled.
Claude Code asks for these when you enable the plugin. Sensitive values are stored in your system keychain.
TypeSafe API keytypesafe_api_key
Only needed after `guard-rail model jev`. Without it Jev is never called and the regex layer decides alone.
Sensitivestring
Keep personal data out of the model, without stopping your work.
guard-rail is a plugin for Claude Code. It hooks the point where tool results
reach the model and replaces personal data — national IDs, emails, phone numbers,
IBANs, addresses — with stable, reversible pseudonyms. The model sees
EMAIL_001; you keep a local map back to the real value. Prompts you write
yourself are checked too, and blocked when they carry personal data, because that
hook cannot rewrite text.
Detection is regex with check-digit validation, so document numbers and system
identifiers survive untouched. An optional model covers free-text names the
regex cannot reach: a local one served by Ollama by default, or TypeSafe's Jev
if you opt in with guard-rail model jev. With the default, nothing leaves your
machine.
Redaction is not a guarantee. Names in free text pass through by default, results above a size limit pass uninspected, and a plugin whose hooks never fire protects nothing while looking installed. Read What this tool does not protect before you rely on it, and run
guard-rail doctorafter installing.
A query against a business system returns real data:
LIFNR | NAME1 | EMAIL | CPF | BELNR
0010000006 | Comercio Atlantico | [email protected] | 529.982.247-25 | 5105600787
0010000006 | Comercio Atlantico | [email protected] | 52998224725 | 5105600788
0010000012 | Norte Distribuicao | [email protected] | 111.444.777-35 | 5105600790
The model receives this instead:
LIFNR | NAME1 | EMAIL | CPF | BELNR
0010000006 | Comercio Atlantico | EMAIL_001 | CPF_001 | 5105600787
0010000006 | Comercio Atlantico | EMAIL_001 | CPF_001 | 5105600788
0010000012 | Norte Distribuicao | EMAIL_002 | CPF_002 | 5105600790
Three things are happening.
System identifiers survive. Supplier numbers, document numbers, column names. Redacting those would make the result useless to work with, so every numeric detector validates a check digit before it fires.
Pseudonyms are stable. The same email is EMAIL_001 on both rows, so the
model can still tell those two documents belong to one person and reason about
duplicates. 529.982.247-25 and 52998224725 share a label too — formatting is
normalised before comparison.
You can go back.
$ guard-rail map EMAIL_001
[email protected]
$ guard-rail map -t "the record for EMAIL_001 is duplicated"
the record for [email protected] is duplicated
Every intervention is recorded in ~/.cache/guard-rail/violations.jsonl — one
JSON object per line, appendable, greppable, ready for a SIEM.
$ guard-rail log
🔴 2026-09-07 08:12:15 redigido mcp__abap-adt__runQuery
• Email: 2× EMAIL_001, EMAIL_002
• CPF: 2× CPF_001, CPF_002
🔴 2026-09-07 08:12:15 BLOQUEADO UserPromptSubmit
• CPF: 1× —
🔴 2026-09-07 08:12:15 PASSOU EM CLARO mcp__abap-adt__tableContents
↳ resultado com 965000 chars excede max_output_chars=400000
| Action | Meaning |
|---|---|
redacted | Value replaced by a pseudonym. Work continued. |
blocked | Prompt stopped. Nothing left the machine. |
not_redacted | Data passed in the clear. The event worth investigating. |
degraded | Local model unavailable; only the regex layer was active. |
armed | A session started with hooks running. |
The log stores pseudonyms, never real values. A log holding the data would be a
worse repository than the original: it grows without bound and nobody remembers
it exists. Cross-reference with guard-rail map when you need the value.
guard-rail log --today
guard-rail log --leaks # only what passed in the clear
guard-rail log --summary # aggregated by violation point
guard-rail log --json
npx claudepluginhub williansaez/guard-rail --plugin guard-railPlugins from other owners that cover similar ground
Built from public signals: copy clicks on this site, GitHub stars and activity, the README and the manifest. Not a security audit or an endorsement.