Allow configuring the callback server bind host - #2
Open
TheGreatAxios wants to merge 1 commit into
Open
Conversation
The callback server hardcoded a 127.0.0.1 bind. Clients whose registered redirect URI is localhost-based (Codex at localhost:1455) never receive the provider's redirect on hosts that resolve localhost to ::1 with no IPv4 fallback, because the loopback server is unreachable over IPv6. CallbackServerConfig gains an optional host field; the default stays 127.0.0.1, so 127.0.0.1-registered callers (xAI) are unaffected. Loopback-only is enforced: localhost, ::1, and 127.0.0.0/8 are accepted; wildcard and routable hosts are rejected up front, and port-in-use errors name the configured host.
TheGreatAxios
force-pushed
the
upstream
branch
from
September 8, 2026 03:44
f86ed02 to
6a01069
Compare
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.
Summary
startCallbackServerhardcoded a127.0.0.1bind. Clients whose registered redirect URI islocalhost-based (e.g. Codex atlocalhost:1455) never receive the provider's redirect on hosts that resolvelocalhostto::1with no IPv4 fallback, because the loopback server is unreachable over IPv6.CallbackServerConfiggains an optionalhostfield. The default stays127.0.0.1, so existing callers with127.0.0.1-registered redirect URIs (e.g. xAI) are unaffected. A round-trip test binds::1and completes a full redirect through the configured host.Test plan
bun run check(typecheck, eslint, prettier,bun test) — 8 pass / 0 fail, including the new "listens on the configured host" round-trip test.