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 base protocol leaves authorization as an OPTIONAL feature and delegates it to a separate framework for HTTP. This lesson sets the framing; Part 9 develops the full framework.
A stdio server is a subprocess launched by the host: it shares the user, permissions and environment of the process that launches it. There is no "unauthenticated request" to protect with OAuth; the risk lies in which command is executed and what it can do with the host's privileges. That is why the security guidelines for local servers focus on consent prior to launch, sandboxing and, if the local server opens an HTTP port, on requiring a token or using restricted IPC.
When the server is remote, every POST MUST carry Authorization: Bearer <token> if the server requires authorization; the server acts as an OAuth resource server, validates the audience and responds 401 with WWW-Authenticate when it is missing or invalid. None of this is negotiated in JSON-RPC: it happens at the HTTP layer before the MCP message is processed. That is why the framework is called "transport-level".
It fits with statelessness: the authorization presented in a request is an input of that request. Listings (tools/list, etc.) MAY vary according to it, and private caches MUST NOT be shared between different authorization contexts.
1. What does the core say about authorization in stdio?
The OAuth framework is for HTTP; stdio takes credentials from the environment.
2. Is authorization mandatory in MCP?
The spec declares it OPTIONAL and recommends the framework for HTTP.
3. Where does bearer token validation happen?
It is transport-level authorization: Authorization header and HTTP 401/403 responses.