Purpose and Scope
Threat modeling MCP systems is a structured way to examine how an application using the Model Context Protocol could be attacked, what an attacker could gain, and which controls would reduce the likelihood or impact. It is performed during design and revisited when tools, servers, permissions, data flows, or deployment conditions change. It does not prove that a system is secure or replace security testing, incident response, or operational monitoring.
An MCP deployment may include a host application, a model, MCP clients, one or more MCP servers, external services, and people who configure or approve actions. The security question is not simply whether each component works as intended. It is also whether their combined behavior lets untrusted content influence a privileged action, or lets a component access information beyond its intended purpose.
A useful model names the assets that matter, the trust boundaries between components, the identities and permissions in use, the possible adversaries, and the paths from an initial foothold to an unwanted outcome. Assets include credentials, private records, tool availability, and the integrity of actions such as sending a message or changing a production resource. The analysis should be specific enough to test.
Map the System and Its Trust Boundaries
Start by describing a real workflow. For example, a staff member asks an assistant to summarize a support case. The host sends the request to a model, the model calls an MCP server that retrieves case details, and the host presents a response. Draw each component and the data and control flows between them. Mark where identity is authenticated, where authorization is checked, where data enters, and where results leave the organization.
A trust boundary is a point where data or authority passes between parties with different levels of trust. A customer message is untrusted even if it is stored in an internal database. An MCP server may be operated by the organization yet still be a separate trust boundary if its dependencies, credentials, or deployment process are independently controlled. The model’s context is another important boundary: retrieved text can influence model behavior, but it should not automatically gain authority to authorize tools.
Record the permissions of each component rather than relying on broad labels such as “internal” or “trusted.” Ask which credentials the server uses, which users’ data it can access, whether credentials are shared, and whether the host can distinguish one user’s authority from another’s. These details reveal whether a compromise in one area could cross into unrelated systems.

Analyze Common Attack Paths
Prompt injection occurs when instructions embedded in user input or retrieved content attempt to alter the model’s behavior. A support case might contain text telling the assistant to retrieve another customer’s record. The text can be returned by a legitimate tool and still be adversarial. The cause is the model’s tendency to interpret natural-language content as instructions; the consequence can be an unauthorized tool call if the host or server relies on the model to enforce access policy.
Tool misuse occurs when a tool is invoked with excessive scope, inappropriate arguments, or at an unsuitable point in a workflow. A read-only search tool presents different risks from a tool that can delete records or send external messages. Confused-deputy behavior is a related but distinct failure: a privileged component uses its authority on behalf of a requester who does not have that authority. For example, a server using a broad service credential might return confidential data because the model requested it, even though the user is not entitled to see it.
Data exposure can arise through tool results, model responses, logs, traces, or error messages. Information may be disclosed to an unauthorized user, sent to an external destination, or retained longer than intended. A compromised MCP server can also manipulate responses, steal credentials accessible to it, or make unauthorized calls to systems reachable from its environment. Consider the chain: malicious content enters a retrieved record, influences a tool request, and reaches a service account with broad access. Modeling the chain clarifies which controls must interrupt it.
Assess and Reduce Risk
For each attack path, state the preconditions, the action an attacker or unsafe component takes, the affected asset, and the likely impact. Distinguish evidence from assumptions. Evidence might include a tool’s documented permission scope or a tested authorization rule; an assumption might be that every user has the same access. Record uncertainties as items to verify instead of treating them as safeguards.
Prioritize by combining likelihood and impact, while considering reachability and existing controls. A low-probability path that exposes all customer records may deserve attention before a likely path with limited, reversible impact. Avoid false precision: a numerical score is useful only if the team uses consistent definitions and the score does not hide severe consequences. Identify an owner and a concrete next action for each high-priority risk.
Prefer controls that enforce authority outside the model. Apply authorization at the service that owns the data, scope credentials to the minimum required operations and records, and separate read actions from consequential writes where practical. Validate tool arguments and constrain destinations. Require human approval when an operation has significant or difficult-to-reverse consequences. Treat tool output as untrusted content; asking the model to ignore malicious instructions is not an access-control boundary.
Operate and Reassess
For a third-party or internally operated MCP server, assess provenance, update practices, dependency integrity, credential handling, and the network access it requires. Restrict the server’s environment so compromise does not provide a path to unrelated systems. Rotate credentials when exposure is suspected, and make tool usage observable through logs that identify the actor, operation, authorization result, and relevant target. Logging should avoid copying secrets or unnecessary sensitive content into a second store.
Monitoring helps detect behavior that a design review cannot rule out. Establish expected patterns for sensitive operations, such as which identities may use them and what rate or target range is normal. Define who investigates an unexpected call and how access can be revoked. Test representative attack paths in a controlled environment, including malicious retrieved content, unauthorized record requests, and server compromise assumptions. A test result is evidence about the tested configuration, not a guarantee about every future deployment.
Revisit the model when a new tool is added, permissions change, a server moves to a new operator, or an incident reveals a missed path. Keep the record concise enough to maintain: system map, prioritized threats, chosen controls, owners, and unresolved assumptions. This connects architectural reasoning to production decisions and makes it possible to verify whether the mitigations still match the deployed system.
Summary
Threat modeling MCP systems focuses on interactions among the model, host, client, servers, tools, users, and external services. The central risks include instruction-bearing untrusted content, tools with excessive authority, confused-deputy behavior, data exposure, and compromised servers. For each, trace a plausible path from entry point to asset and impact, then place enforceable controls at the boundaries where identity, authorization, data, and actions are handled.
The most reliable approach is layered: limit permissions, enforce authorization in the owning service, constrain and validate tool actions, protect server integrity, monitor sensitive operations, and reassess after changes. The model can assist a workflow, but it should not be the system’s sole security boundary. A threat model is useful when it leads to specific tests, accountable owners, and controls that can be observed in production.
Lesson Checkpoint
Review what you learned and get feedback on your work.