Skip to content

Merge dev into main — edge auth, Keycloak support, openshell integration - #10

Merged
oidebrett merged 12 commits into
mainfrom
dev
Apr 1, 2026
Merged

oidebrett merged 12 commits into
mainfrom
dev

Conversation

@oidebrett

Copy link
Copy Markdown
Owner

Summary

Merging dev branch into main. Key features included:

  • Edge auth for OpenShell — bearer token validation at /_ws_tunnel route for WebSocket gateway auth
  • Keycloak provider support — full Keycloak IdP integration with JWT validation
  • IdP provider selection — internal/Google/Keycloak provider selection
  • Merging this PR will auto-trigger CI to push oideibrett/mcpauth:latest to Docker Hub

Test plan

  • mcpauth authenticates openshell WebSocket connections
  • Keycloak provider validates tokens correctly

🤖 Generated with Claude Code

ivobrett and others added 12 commits January 9, 2026 15:25
- Implemented Keycloak OAuth provider with token introspection
- Added support for Keycloak-specific configuration (host, port, realm)
- Updated authHandler to use introspection for Keycloak tokens
- Added audience validation for MCP server URLs
- Updated metadata endpoints to point to Keycloak when configured
- Added environment variables and CLI flags for Keycloak setup
- Updated README with Keycloak configuration guide and examples

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- Added KEYCLOAK_AUTH_PROTOCOL environment variable
- Keycloak provider now supports both HTTP and HTTPS
- Defaults to HTTPS for production use
- Port is omitted from URLs when using standard ports (80/443)
- Updated README with protocol configuration

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- oauthAuthorizationServerHandler now returns Keycloak endpoints when configured
- Previously always returned mcpauth's /authorize endpoint
- This was causing clients to hit non-existent /authorize on oauth domain
- Now properly returns Keycloak's protocol/openid-connect/auth endpoint

Fixes: Page not found error when redirecting to authorization endpoint

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- Added /.well-known/oauth-protected-resource/mcp route
- MCP protocol requires the /mcp suffix for resource metadata
- Route serves same metadata as base endpoint

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- Detailed Keycloak client configuration steps
- Redirect URIs for production, development, and MCP Inspector
- Web Origins configuration for CORS
- Audience mapper setup (critical for token validation)
- Keycloak reverse proxy configuration
- Traefik public endpoint configuration
- Testing instructions for MCP Inspector and Claude Desktop
- Troubleshooting section for common issues
- Reference to official MCP guide

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@oidebrett
oidebrett merged commit bece86a into main Apr 1, 2026
1 check passed
@oidebrett
oidebrett deleted the dev branch April 27, 2026 15:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants