For your agents · Maskflare Coding Agents
Keep Secrets and Customer Data Out of Claude Code, Cursor and Codex
What the developer pastes
Why does this fail?
OPENAI_API_KEY=sk-proj-7Hq2…Xv9
DATABASE_URL=postgres://app:S3cr3t!pw@db
customer: ada@example.com
What the coding agent sends
Why does this fail?
OPENAI_API_KEY=mf_mask_c03a
DATABASE_URL=postgres://app:mf_mask_88b1@db
customer: mf_mask_5e1d
574
Built-in detectors for personal data and secrets
47
Country packs, checksum-validated where the format has one
9
AI providers behind one gateway, plus the desktop agent and proxy
Sound familiar?
Why the usual answers fall short
“We have secret scanning in CI.”
It runs after the commit. The agent sent the key to the model an hour earlier.
“Our devs know better.”
They do, until they paste a failing request with the Authorization header still in it.
“We'll just block the agent.”
Then you lose the productivity you bought it for. Mask the secret, keep the agent.
A coding agent reads files, runs shell commands and fetches URLs on its own. One cat of a .env file or a database dump and the credentials are in the next request to the model.
Secret scanners in CI catch keys after they're committed. By then the same key has already been sent to an AI provider, often more than once.
How Maskflare Coding Agents works
The maskflare-hook command plugs into each coding agent's hook system. In Claude Code it blocks a prompt that contains a match and masks the input and output of Bash, WebFetch, Write, Edit and MCP tools. Cursor and Codex CLI get the protections their hook APIs allow. Detection uses the same 232 credential formats and personal-data detectors as the rest of Maskflare.
- 01
Install the SDK
pip install maskflare on the developer machine or in your devcontainer image.
- 02
Install the hook
Run maskflare-hook install for Claude Code, Cursor or Codex CLI. It writes the agent's hook configuration.
- 03
Work as normal
Prompts with secrets are stopped with a clear message; tool input and output is masked before the model sees it.
Benefits
Stops secrets at the prompt
A prompt that contains an API key, token or private key is blocked before it's sent.
Masks tool traffic
Shell output, fetched pages and file edits are masked before they go back into the model's context.
232 credential formats
Cloud keys, AI provider keys, database URLs, private keys, OAuth tokens and more.
Same policy
Rules come from your Maskflare environment, so security sets them once for everyone.
Capabilities
Claude Code
Prompt blocking plus masking of Bash, WebFetch, Write, Edit and mcp__* tool input and output.
Cursor and Codex CLI
Prompt and tool protections within the limits of each agent's hook API.
MCP
MCP servers the agent uses can also be routed through the gateway's MCP route.
Set it up
pip install maskflare
maskflare-hook install claude-codemaskflare-hook install cursor
maskflare-hook install codexWhat it does not do
We'd rather you hear it from us.
- Hooks see what each agent's hook API exposes; the capability matrix shows what is covered per agent.
- Hooks protect the developer machine where they're installed. For shared environments, bake them into your devcontainer or base image.
Explore related capabilities
See how Maskflare applies the same masking rules to related AI and data-protection workflows.
Related guides and explainers
Frequently asked questions
Which coding agents are supported?
Claude Code, Cursor and Codex CLI. Claude Code has the widest coverage because its hook API exposes the most.
Does it slow the agent down?
Masking adds a few milliseconds per call with the default rules, which you won't notice next to model latency.
What does the developer see when a prompt is blocked?
A short message naming the rule that matched, never the secret itself, so they can remove it and try again.
Can we enforce it for every developer?
Install the hook in your devcontainer or base image and manage the rules centrally in the Maskflare console.
See it on your own data
Try Maskflare free.
Bring your hardest prompts.
28-day free trial or 10,000 requests, whichever comes first. Point one app at the gateway or enroll a few laptops,
and watch what gets masked. Or talk to us first.
- SOC 2 Type II: In progress
- ISO 27001: In progress
- EU hosting by default · on-premises available
- Prompts and files never stored
- Never used to train AI models
- GDPR · nDSG · DPA available
- Trust center →