mcp-oidc-proxy
mcp-oidc-proxy
Local prototype for exercising FastMCP OIDCProxy against a demo OIDC provider.
The repository packages two cooperating apps:
Auth server — a NanoIDP demo OIDC provider on
http://127.0.0.1:9000MCP server — a FastMCP HTTP server on
http://127.0.0.1:8000with a single protectedhello_worldtool
Together they prove that an MCP client can authenticate through OIDCProxy, call a protected tool, and be rejected when unauthenticated.
Prerequisites
Python 3.14+
Setup
uv sync
cp .env.example .envDemo client credentials are committed in config/ with defaults matching .env.example. Both servers read the same environment variable names so credentials stay aligned.
Running locally
Run each server in its own terminal from the repository root:
uv run python -m nanoidpuv run launch-mcpThe auth server listens on http://127.0.0.1:9000 and exposes standard OIDC discovery, JWKS, authorize, and token endpoints. NanoIDP reads committed configuration from ./config.
Demo-only warning: the auth server exists solely to validate the OIDC proxy flow during local development and testing. It is not a production identity provider.
Demo credentials:
User:
admin/adminOAuth client: values from
.env.example(mcp-proxy-client/dev-secret)
Tests
uv run pytest # unit/integration tests (smoke excluded)
uv run pytest -m smoke # end-to-end smoke tests (spawns both servers)Smoke tests launch real subprocesses for NanoIDP and the MCP server, complete the OAuth flow with FastMCP HeadlessOAuth, and verify both authenticated and unauthenticated tool calls.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Pappa/mcp-oidc-proxy'
If you have feedback or need assistance with the MCP directory API, please join our Discord server