Skip to content

Suppport IPv6 and dual-stack ADB server connections in ppadb - #121

Open
beshaya wants to merge 1 commit into
Swind:masterfrom
beshaya:ipv6
Open

Suppport IPv6 and dual-stack ADB server connections in ppadb#121
beshaya wants to merge 1 commit into
Swind:masterfrom
beshaya:ipv6

Conversation

@beshaya

@beshaya beshaya commented Aug 28, 2026

Copy link
Copy Markdown

When forwarding the ADB server port (5037) through SSH tunnels or on IPv6-enabled hosts (e.g., Rodete), the daemon binds to IPv6 loopback (::1:5037). ppadb previously hardcoded socket.AF_INET (IPv4 only) and 127.0.0.1, which caused connection attempts to fail with [Errno 111] Connection refused.

This change:

  • Updates ppadb.connection.Connection.connect() to resolve the host via socket.getaddrinfo(), supporting both IPv6 and IPv4 sockets.
  • Updates default Client host to 'localhost'.

When forwarding the ADB server port (5037) through SSH tunnels or on IPv6-enabled hosts (e.g., Rodete), the daemon binds to IPv6 loopback (`::1:5037`). ppadb previously hardcoded `socket.AF_INET` (IPv4 only) and `127.0.0.1`, which caused connection attempts to fail with `[Errno 111] Connection refused`.

This change:
- Updates `ppadb.connection.Connection.connect()` to resolve the host via `socket.getaddrinfo()`, supporting both IPv6 and IPv4 sockets.
- Updates default `Client` host to `'localhost'`.
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.

1 participant