Repository navigation
Conversation
Contributor
Author
|
Future Enhancement Note: Dynamic port allocation (binding to port |
christso
marked this pull request as draft
December 27, 2025 01:17
christso
force-pushed
the
feat/oauth-public-client-fallback
branch
4 times, most recently
from
December 27, 2025 05:43
3eef5d6 to
01fb104
Compare
Update MCP SDK to get latest OAuth improvements including better public client support. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <[email protected]>
Add support for OAuth public clients (no client secret) with configurable redirect URI. This enables MCP servers that don't support dynamic client registration to work with pre-registered public OAuth clients. Changes: - Add redirectUri option to McpOAuthConfig for flexible callback configuration - Add parseRedirectUri() helper to extract port/path from URI string - Update oauth-callback server to accept redirectUri parameter - Support public clients via token_endpoint_auth_method: "none" - Update config schema and CLI debug command The redirectUri approach is cleaner than separate port/path options and matches standard OAuth library patterns, making debugging easier. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <[email protected]>
Add test coverage for McpOAuthCallback.ensureRunning() including: - Default port/path behavior - Custom redirectUri parsing - Server restart on config change - Idempotent behavior - Start/stop lifecycle 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <[email protected]>
christso
force-pushed
the
feat/oauth-public-client-fallback
branch
from
December 27, 2025 21:16
ed54e4f to
914d122
Compare
- Remove redundant tests (duplicate default/isRunning checks) - Add dedicated parseRedirectUri unit tests for port/path parsing - Test edge cases: http/https defaults, invalid URIs 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <[email protected]>
christso
marked this pull request as ready for review
December 27, 2025 23:38
This was referenced Dec 28, 2025
|
Any blockers on this? I'm currently instructing the agent to use github CLI but it kinda drain tokens |
Contributor
Author
|
closing this to address the two issues separately:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #5766
Summary
redirectUrifor OAuth callback (simpler than separate port/path)Problem
Wrong authorization URL: MCP SDK 1.15.1 incorrectly constructs the authorization URL by appending
/authorizeto the issuer URL instead of usingauthorization_endpointfrom OAuth metadata.No callback config: Users cannot configure the OAuth callback URL to match what's registered on their OAuth server.
Solution
Upgrade MCP SDK to 1.25.1 which correctly reads
authorization_endpointfrom OAuth discovery metadata.Add
redirectUriconfig option: A single URI string that specifies the full callback URL. This is cleaner than separate port/path options and matches standard OAuth library patterns.User Configuration
If
redirectUriis not specified, the defaulthttp://127.0.0.1:19876/mcp/oauth/callbackis used.Why
redirectUriinstead ofcallbackPort/callbackPath?Test plan
ensureRunningbehavior with custom URIs🤖 Generated with Claude Code