part…
Building governance for MCP?
The gateway applies what the guide teaches: policies on discovery, invocation and authorisation.
The gateway applies what the guide teaches: policies on discovery, invocation and authorisation.
The Local Server Security guide covers a threat model distinct from the protocol: your machine. A local server is an ordinary process launched by the host as your user: it inherits environment variables, reads whatever you can read (SSH, cloud credentials, browser profiles) and opens outbound connections. None of that is governed by the protocol; it is governed by how you run it.
A stdio client and server share a single trust domain: neither the protocol nor the SDKs defend one from the other; the server is already executing code by virtue of having been launched. Consequences: security decisions happen before launch (provenance) and at launch (isolation); if you want reduced privileges, you draw the boundary yourself (container, sandbox, VM). It is also cumulative: all configured servers share the model's context, so a malicious one can influence how the agent uses the others' tools.
Guiding principle: nothing proves what a server will do; treat it as untrusted code with exactly the privileges you give it, and give it the minimum.
latest) and know what the pin covers (npx/uvx pin only the root package; an image by digest @sha256: freezes the whole tree); prefer artefacts with signatures, attestations and an SBOM; going further: verify signatures (Sigstore) and generate your own SBOM (Syft, Trivy).~/.ssh, ~/.aws are credentials; going further: short-lived credentials issued at launch and rotation when a server is retired.$HOME), read-only if that suffices; configuration allowlists are cooperative, real enforcement comes from isolation.--network=none); filter the rest with an outbound firewall or a proxy with a domain list; alert on unexpected destinations. Note: whatever listens on a local port (bridges, local HTTP servers) is reachable by other processes and by the browser; 127.0.0.1 is not authentication.Local servers are software installed by users, and they will not ask you. Initial posture: a list of approved servers with pinned versions and admission criteria; a documented default execution posture (e.g. "in a container without mounting the home directory"); central deployment of whatever does not need local access; continuous inventory of client configurations (they live at known paths); logging of MCP activity; a plan for the fleet-wide incident (find instances, block egress, rotate credentials, push a pinned version; SBOMs answer "who uses the affected SDK"); regulatory context (e.g. the EU CRA).
SEP-1024 sets the client requirements when installing local servers (consent showing the exact command). The Inspector has its own threat model (the Security page): it is a tool that executes commands and stores secrets; its catalogue redacts sensitive fields (servers/show) but not credentials embedded in URLs or in args; it uses a secrets store; and the loopback OAuth flow must not run in CI (--stored-auth-only).
1. What does version pinning with npx or uvx cover?
Transitive dependencies are resolved at install time; an image by digest does freeze the tree.
2. What is the highest-leverage mitigation according to the guide?
It protects even when provenance fails.
3. What are the allowed-directory lists in a server's configuration?
A malicious server can ignore them; the container cannot be ignored.
4. What signal does a server give when it only wraps a SaaS API and is distributed solely as stdio?
That is exactly how a malicious or over-collecting server gets in.