macOS ChatGPT/Codex app does not attempt Remote SSH connections to private LAN IP addresses
What version of the Codex App are you using (From “About Codex” dialog)?
ChatGPT 26.715.61943 / codex-cli 0.144.6 (remote)
What subscription do you have?
ChatGPT Pro
What platform is your computer?
Darwin 25.5.0 arm64 arm
What issue are you seeing?
Remote SSH connections from the unified ChatGPT/Codex macOS app fail with:
undefined error 0
The failure occurs only when connecting to a private LAN address:
192.168.0.2:22
Remote SSH connections to a public WAN host work normally from the same application.
The LAN SSH host is also reachable successfully from macOS Terminal.
Steps to reproduce
Configure an SSH host using a private LAN IP address:
Host hostname
HostName 192.168.0.2
User user
Port 22
Confirm that SSH works from Terminal:
ssh hostname
Open the unified ChatGPT/Codex macOS application.
Open Settings → Connections → SSH.
Attempt to connect to the LAN host.
The application returns:
undefined error 0
Configure or select a public WAN SSH host.
The WAN SSH connection succeeds normally.
Network capture results
I monitored LAN SSH traffic using:
sudo tcpdump -n -i any 'host 192.168.0.2 and tcp port 22'
After triggering the connection from the ChatGPT/Codex app:
0 packets captured
No TCP SYN packet is sent to the LAN host.
I then monitored a public WAN SSH connection:
sudo tcpdump -n -i any 'host example.com and tcp port 22'
The application sent TCP SYN packets, completed the TCP handshake, and exchanged SSH data normally.
This indicates that the failure occurs before the macOS app initiates the LAN TCP connection.
Additional verification
The following command succeeds:
ssh alma 'echo $SHELL; echo $PATH; command -v codex; codex --version'
Output:
/bin/bash
/home/user/.local/bin:...
/home/user/.local/bin/codex
codex-cli 0.144.6
Node.js is also available:
/home/user/.nvm/versions/node/v22.17.0/bin/node
v22.17.0
The app has network client entitlement:
com.apple.security.network.client = true
com.apple.security.app-sandbox = false
The application contains NSBonjourServices, but NSLocalNetworkUsageDescription does not appear to be present in its Info.plist.
Resetting the macOS Local Network permission did not resolve the issue:
tccutil reset LocalNetwork com.openai.codex
Using the IP address directly instead of an SSH alias also produces the same error.
Expected behavior
The macOS application should initiate an SSH connection to private LAN IP addresses when the host is reachable and Terminal SSH works.
If local network permission is required, the application should request it and display a meaningful error rather than:
undefined error 0
Actual behavior
The application does not send any packet to the private IP address and immediately displays undefined error 0.
Public WAN SSH connections from the same application work normally.
What steps can reproduce the bug?
- Configure an SSH host that points to a private LAN address, such as 192.168.0.2:22.
- Confirm that the host is reachable from macOS Terminal using
ssh hostname. - Open the ChatGPT/Codex macOS app.
- Open the Remote SSH connection screen.
- Select or add the LAN SSH host.
- Attempt to connect.
- The app immediately displays
undefined error 0. - Run tcpdump while retrying the connection:
sudo tcpdump -n -i any 'host 192.168.0.2 and tcp port 22'
- No packets, including TCP SYN packets, are captured.
For comparison, connecting from the same app to a public WAN SSH host works and tcpdump shows a normal TCP and SSH exchange.
Feedback ID: no-active-thread-019f8520-7e40-7b11-ade1-eef2b0b14ed9
What is the expected behavior?
The macOS app should initiate an SSH connection to a reachable private LAN IP address in the same way it does for a public WAN address.
If macOS Local Network permission is required, the app should request that permission and show a clear error message when access is denied.
Additional information
- SSH from macOS Terminal to 192.168.0.2 works normally.
- Remote SSH to a public WAN host works from the same ChatGPT/Codex app.
- Using the private IP address directly instead of an SSH config alias produces the same error.
- Resetting Local Network permission for com.openai.codex did not resolve the issue.
- The app bundle ID is com.openai.codex.
- The app has com.apple.security.network.client enabled.
- No LAN packets are emitted by the app during the failed connection attempt.
Update: I found a workaround.
Running the following command and rebooting macOS restored Remote SSH access to the private LAN host:
sudo defaults write com.apple.network.local-network \
AllowedWiFiLocalNetworkAddresses -array "192.168.0.0/24"