Your server works on localhost. Now it has to live at https://mcp.yourcompany.com, act for real users on their real accounts, and be added from Claude, ChatGPT and VS Code by people you've never met. Sign-in is where most remote servers go wrong, and where the 2026-07-28 spec changed the most.
The shape of it
Your MCP server is a resource server. When an app calls it without a valid token, it answers with an authorization challenge; the app then sends the user through an OAuth flow with your authorization server, gets a token issued for your MCP server, and retries. Apps such as Claude call remote servers from their own cloud, so your server and its sign-in must be reachable on the public internet.
What changed in 2026-07-28
- Client registration: CIMD, not DCR. Dynamic Client Registration is deprecated in favour of Client ID Metadata Documents, where the client's ID is a URL to a document describing it. Support CIMD now; keep DCR during the window if existing clients rely on it.
- Issuer validation. Clients must check the issuer (
iss) before redeeming an authorization code, which blocks mix-up attacks between authorization servers. Make sure your authorization server sends it. - Localhost redirects for desktop and CLI apps.
application_typein registration lets them uselocalhostredirect URIs. - Issuer-bound credentials. Client credentials can't be reused across authorization servers.
Rules from the security best practices
- Accept only tokens issued for your server (check the audience). Never forward a client's token to another API ("token passthrough" is forbidden by the authorization spec).
- If you proxy a third-party API with one fixed client ID, ask each client for consent before sending the user to the third party, or an attacker can ride an earlier consent cookie.
- Start with minimal scopes and ask for more when a privileged tool is first used.
- Verify every request, and never treat a state handle (a cart or job ID) as authentication.
- If your authorization server fetches client metadata URLs (CIMD), apply SSRF protections: https only, no private or link-local addresses.
Company-managed access
Enterprise-Managed Authorization, stable since 18 June 2026, lets a company grant your server to its people through its identity provider: the client exchanges an identity assertion from the IdP for an access token from your authorization server, and users skip per-server consent. The MCP blog lists Asana, Atlassian, Canva, Figma, Granola, Linear and Supabase among servers that support it. If you sell to companies, it's worth planning for.
Test it like a user
In short
- Your server is a resource server: challenge, OAuth, token issued for you.
- 2026-07-28: CIMD over DCR, issuer validation, localhost redirects for native apps.
- Check token audience, never pass tokens through, start with small scopes.
What to try next
Share this lesson- Re-run the security checklist.
- Defend the other side of the loop: prompt injection for builders.