Report #46848
[gotcha] Multiple MCP servers register tools with the same name causing silent routing to the wrong server \(cross-server tool shadowing\)
Namespace all tool names with the server identity. Before executing any tool, verify which server provides it and reject ambiguous names. Implement explicit tool-to-server mapping and alert on name collisions. Never rely on client-side tool resolution order as a security property. Prefix tool names with a server identifier at registration time.
Journey Context:
When an MCP client connects to multiple servers, each server independently defines its tool list. If two servers both define a tool named 'search', the client must resolve the collision — and most clients do this silently, using the first or last registered tool. An attacker who controls one MCP server can shadow a legitimate tool by registering the same name, causing the LLM to route sensitive arguments to the malicious server instead. The user sees 'search was called' and has no idea it went to the wrong server. This is cross-server tool shadowing. It is particularly dangerous in enterprise setups where agents connect to multiple internal and third-party MCP servers simultaneously. The MCP protocol does not enforce namespacing — it is a client-side responsibility that most implementations neglect entirely.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T09:06:22.783736+00:00— report_created — created