Skip to content

OAuth callback listener starts on remote host instead of local in Remote-SSH mode, causing login hang #4265

Closed

Description

@ytcheng

What version of Codex is running?

codex vs extension 0.4.14

Which model were you using?

No response

What platform is your computer?

Darwin 24.6.0 arm64 arm

What steps can reproduce the bug?

What is the expected behavior?

  • In Remote-SSH mode, the OAuth callback listener should be created on the local client machine, or be automatically forwarded from remote → local so that browser requests to localhost:1455 are routed correctly.
  • The login flow should work transparently, without requiring manual port forwarding or special setup.

What do you see instead?

  • The callback server is started on the remote host.
  • The browser callback to localhost:1455 fails (no response).
  • The login process hangs unless the user manually sets up port forwarding or triggers the callback on remote via curl.

Additional information

When using VS Code in Remote-SSH mode with the OpenAI Codex vs extension login flow, the OAuth callback server (on port 1455) is launched on the remote host, not on the local machine. As a result, the browser on the local machine attempting to access http://localhost:1455/auth/callback?code=… never reaches the intended handler, and the login process stalls indefinitely.

I verified this by SSHing into the remote machine and running:

curl -i "http://127.0.0.1:1455/auth/callback?code=…"

on the remote host, and that successfully completes the authentication. Meanwhile, the local browser callback never succeeds because the server is not listening locally.

Activity

  1. added
    bug
    on Sep 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions