MCP: Gateways, Shadow Servers, and Discovery

How agents find tools, which MCP servers exist in an environment, and who those tools act for.

MCP is how agents find and call tools. The hard part is not the protocol. It is knowing which servers exist, what they can do, and who they act for.

These posts define the gap and show the controls that hold. Incident write-ups that started as an MCP failure and turned into a control failure are in Agent Security.

Start here

  1. What Is an MCP Gateway? agentgateway Examples An MCP gateway sits between AI agents and MCP servers: one endpoint, sign-in, per-tool CEL rules and audit. How it differs from LLM and API gateways.
  2. What Is Shadow MCP? A Plain Definition What is shadow MCP? Any MCP server your AI tools can reach that security did not approve and cannot see, plus where it comes from and why it is a risk.
  3. How to Find Shadow MCP Servers in Your Environment How to find shadow MCP servers on the network, in Kubernetes, on laptops, and in vendor accounts, then check them against a registry you approved.

Every post in this hub

  1. How to Fingerprint an MCP Server
    Identify an MCP server from one request: server/discover first, then initialize, then SSE. What every 200, 400, 404, 405 and 403 reply means.
  2. MCP Gateway Not Blocking Shadow Servers?
    Why an MCP gateway is not blocking shadow MCP server traffic: traffic that skips it, allow-by-default rules, a 200 that is a block, and stale sessions.
  3. How to Run an MCP Registry of Record
    An MCP registry of record is the list your gateway config, allowlists and scans come from. The fields it needs and how agentgateway follows it.
  4. Where Every MCP Client Keeps Its Config
    MCP config file locations for Claude Code, Claude Desktop, Cursor, VS Code, Windsurf, Gemini CLI and Codex, with user, project and managed scopes.
  5. See Which MCP Servers Run on Employee Machines
    See which MCP servers run on employee machines: read each client's config files with a read-only MDM sweep, redact secrets, and know what files miss.
  6. How to Stop Shadow MCP Servers
    Stop shadow MCP servers from reaching company systems: one gateway path with agentgateway, per-call authorization, default-deny egress, and alerts.
  7. Grok Bot on agentgateway codeSearch: 96% Fewer Tokens on Real GitHub Work
    I put Grok Bot's GitHub MCP connector behind agentgateway Enterprise in codeSearch mode. A real PR review workflow went from 89,038 tokens to 3,809.
  8. What Is an MCP Gateway? agentgateway Examples
    An MCP gateway sits between AI agents and MCP servers: one endpoint, sign-in, per-tool CEL rules and audit. How it differs from LLM and API gateways.
  9. How to Find Shadow MCP Servers in Your Environment
    How to find shadow MCP servers on the network, in Kubernetes, on laptops, and in vendor accounts, then check them against a registry you approved.
  10. MCP Progressive Tool Discovery: Native vs. Hand-Rolled
    A 3-tool MCP entry point cuts tools/list bytes 94% vs a flat 50-tool catalog. agentgateway's Search mode does this, Enterprise-only; here's the OSS version.
  11. What Is Shadow MCP? A Plain Definition
    What is shadow MCP? Any MCP server your AI tools can reach that security did not approve and cannot see, plus where it comes from and why it is a risk.
  12. Stateless MCP on Kubernetes: No More Sticky Sessions
    A 3-replica MCP server behind agentgateway, no session affinity, survives a rolling restart mid-session. What the MCP 2026-07-28 spec changed, and the proof.
  13. Conway's Law Is Coming for Your MCP Servers
    Putting every MCP tool behind one federated endpoint rebuilds the ESB and makes agents worse. Why MCP federation should follow business domain boundaries.
  14. Multi-Tenant MCP Servers: Per-Customer Tools
    Run MCP servers multi-tenant: agentgateway gives each customer its own tools, quotas, and chargeback from a JWT claim. The servers hold zero auth code.

Frequently asked questions

What is an MCP gateway?

An MCP gateway is the point on the path that brokers tool calls between agents and Model Context Protocol servers. It is where discovery, identity, and policy can see the same request.

What is shadow MCP?

Shadow MCP is an MCP server that agents are already calling, and that the platform team did not put there. Finding those servers is the first control. Pinning what they can do is the next one.