Skip to content

public oauth client should always support localhost callback#3

Merged
jaingounchained merged 2 commits into
mainfrom
public-client-localhost-callback
Jun 16, 2026
Merged

public oauth client should always support localhost callback#3
jaingounchained merged 2 commits into
mainfrom
public-client-localhost-callback

Conversation

@jaingounchained

@jaingounchained jaingounchained commented Jun 11, 2026

Copy link
Copy Markdown

Summary

Public static OAuth clients defined in the Dex configuration currently do not support wildcard redirect URIs. This creates a compatibility issue when adding support for MCP clients that require fixed, non-localhost callback URLs, such as:

  • cursor://anysphere.cursor-mcp/oauth/callback
  • https://beta.app.kiro.dev/agent/mcp/callback
  • https://gamma.app.kiro.dev/agent/mcp/callback
  • https://app.kiro.dev/agent/mcp/callback

If these redirect URIs are explicitly configured, OAuth clients that rely on localhost-based callback URLs will no longer be able to authenticate successfully.

Change

Enable support for any localhost callback URL for public static OAuth clients while continuing to allow explicitly configured redirect URIs required by MCP clients.

Motivation

This change ensures compatibility with both:

  1. MCP clients that require fixed callback URLs (e.g. Cursor and Kiro).
  2. Existing OAuth clients that use dynamic localhost redirect URIs during local development.

Without this change, adding support for MCP-specific redirect URIs would break authentication flows for clients that depend on localhost callbacks.

@jaingounchained jaingounchained marked this pull request as ready for review June 12, 2026 00:49
@jaingounchained jaingounchained requested a review from sks June 12, 2026 00:54
@jaingounchained jaingounchained merged commit acdb44a into main Jun 16, 2026
2 of 6 checks passed
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