How do credentials leak from MCP configs?
In short: Credentials leak when API keys and tokens sit in MCP client config files, environment variables or logs. OWASP ranks token mismanagement and secret exposure first in its MCP Top 10. A gateway mitigates it by brokering credentials, so the agent and its config never hold the tool's real secret.
What happens?
A config file on a laptop holds a long-lived key for a production tool.
The key leaks through a repository, a backup, a debug trace or a prompt injection.
How does a gateway mitigate it?
- Keep tool credentials at the gateway, not in client configs.
- Issue short-lived tokens per task.
- Mask secrets in traffic and logs.
Which scored gateways document a mitigation?
| Gateway | Documented control | Source |
|---|---|---|
| NewCore | The agent never holds the tool's own credential. | [nc-secure] |
| Aembit | The agent never holds direct credentials. | [ae-home] |
| Idira | The underlying server URL and tokens are not exposed to the agent. | [id-docs] |
| Docker | Secrets managed by the gateway and injected into containers. | [docker-gh] |
| Lasso | Token and secret masking guardrail. | [lasso-gh] |
Facts only. A gateway missing here may still mitigate the threat; we list what its public pages document.
Sources
- OWASP MCP Top 10 [owasp-mcp] read 2026-11-03
- NewCore: Secure [nc-secure] read 2026-11-03
- Aembit home [ae-home] read 2026-11-03
- CyberArk Secure AI architecture [id-docs] read 2026-11-03
- docker/mcp-gateway README [docker-gh] read 2026-11-03
- lasso-security/mcp-gateway README [lasso-gh] read 2026-11-03
All eight threats are listed on the threats hub.
By The Datasheet desk · Published and reviewed 2026-11-03