Applying One Tool-Call Policy to an MCP Tool Shared by Many Agents
Treat the shared MCP tool, not each agent, as the control point. Place a single enforcement point in the execution path between agents and the tool, give every agent a distinct verifiable identity, and write one rule set over tool, caller, arguments, and response with caller-specific conditions where needed. Enforce allow, redact, block, rate limit, or escalate at runtime, and record evidence for every decision.
- Verified caller identity and the time of the call
- Tool name and the arguments evaluated, with sensitive values handled according to your retention rules
- Decision taken: allow, redact, block, rate limit, or escalate
- Rule or rules that produced the decision, and the policy version in force
- What was redacted, and whether the response was inspected
- For escalations: the approver, the outcome, and the time to resolution
- Is it in the execution path, with every route to the shared tool closed except through it?
- Does one rule set apply to all callers, with conditions tied to verified agent identity?
- Are all five decision types supported at runtime, not reviewed after the fact?
- Can policy inspect both arguments and returned responses?
- Is conflict resolution between global rules and caller exceptions defined and testable?
- Does each decision record the policy version in force, and can you retrieve it later?
Why per-agent policy fails for a shared tool
The Model Context Protocol lets AI models and agentic systems discover, access, and interact with external tools, data sources, and services. That convenience means one tool often serves agents built by different teams, on different frameworks, under different identities. When each agent carries its own checks, the tool ends up governed by as many rule sets as it has callers.
The failure modes are predictable. Rules drift because each team updates its own code on its own schedule. Permissions grow broader than any single agent needs, because the tool must stay usable for the most demanding caller. A framework that skips the check, or a new agent that never adds it, leaves the tool exposed. And when a reviewer asks what the tool was allowed to do last quarter, there is no single place to look.
NIST guidance on agent security points the other way. It says separation of policy from reasoning should be enforced by architecture, with policy enforcement established around the agent and between it and the systems, data, and credentials it uses. It also calls for verification of each individual tool invocation based on current state, context, and risk profile. Both point to call-time enforcement outside agent code.
Where to place the enforcement point
Four placements are common. The trade-offs are consistency, bypass risk, and operational overhead. NIST's API protection guidance describes centralized, distributed, and hybrid gateway patterns, where the gateway acts as the policy enforcement point and defers to an authorization system. The same reasoning applies to MCP traffic.
- In-agent checks: Lowest added latency, but policy is duplicated across frameworks, drifts, and depends on each agent's code being correct. Not suitable as the only control for a shared tool.
- Server-side logic in the MCP server: Close to the tool and hard to skip for that server. Rules are tied to one server's code, and caller context may be limited to what the server receives.
- Central intermediary in the execution path: One rule set and one decision point for all callers. It can be bypassed if traffic reaches the tool by another route, so direct network access must be closed.
- Distributed intermediaries beside each tool or agent: Enforcement sits near each workload, which reduces a single shared choke point. Policy distribution and version consistency become the operational burden.
- Hybrid split between agents and a shared layer: Harder to ensure policy is applied consistently and correctly, because responsibility is divided. Use only with a clear rule for which layer owns which decision.
Designing a policy model that applies across callers
Start with identity. Each agent needs a unique, verifiable, non-human identity that is distinguishable from human users and service accounts. Without it, caller-specific conditions cannot be trusted, and every agent collapses into one anonymous caller.
Then define the attributes a single rule set will evaluate: agent identity, tool name, argument values, response content, call rate, and data sensitivity. Arguments matter because the same tool may be safe with one parameter and unsafe with another. Response content matters because tool results re-enter the agent's context and shape its next action, so the response is a separate inspection point from the request. NIST also treats tool descriptions and schemas as untrusted text, and describes rug-pull attacks where a server silently changes tool definitions. Pinning tool definitions to immutable version identifiers helps detect that.
Layer the rules. A global baseline applies to every caller of the tool. Caller-specific conditions then narrow access or add obligations for particular identities, such as a lower rate limit or approval for a sensitive argument. NIST's Policy Machine model separates authorizations, prohibitions, and obligations, and treats reconciling conflicts between simultaneous policies as inherent. A practical conflict rule is that prohibitions in the global baseline cannot be overridden by a caller-specific exception, and any exception must be explicit, owned, and versioned. Keep the policy a managed artifact of its own, separate from agent code.
Decisions to enforce at runtime
Evaluate each proposed call against explicit policy before it executes, and each response before it returns to the agent. Five outcomes cover most needs.
- Allow: The call matches policy for this caller, arguments, and context. Record it anyway.
- Redact: Permit the call but remove or mask sensitive values in the request or in the returned response.
- Block: Refuse the call and return a clear denial to the agent. Use for prohibited tools, arguments, or callers.
- Rate limit: Constrain call volume per caller or per tool when volume itself is the risk.
- Escalate for human approval: Pause the call when it crosses a defined risk threshold and route it to the correct authority. Document the thresholds and tie them to outcomes.
One enforcement point in front of a shared MCP tool
Agents
Different teams, frameworks, and identities calling the same tool.
Enforcement point
One rule set evaluated per call against caller, arguments, and context.
Shared MCP tool
Reachable only through the enforcement point.
Evidence
A decision record for each call, tied to the policy version in force.
Put one policy in front of your shared MCP tools
See how policy is enforced in the execution path for tool calls and MCP servers, and how each decision becomes audit-ready evidence.
See How Evidence Is ProducedHow does your AI governance program compare?
See where your program has gaps in less than 2 minutes.