libssh ssh_connect() connects to the first resolved address only, which for example means that for localhost, resolving to ::1 and 127.0.0.1, it is only connecting to ::1. If the service is not reachable on IPv6 on a dual-stack host, then the connection will fail.
Can be reproduced with in the dual-stack branch in this repository running the interop test, or startingghcr.io/notconf/notconf:26146692186 and running the acton test --tag notconf-server in the netconf repo. This is an older version of notconf, I have since updated it to listen on both IPv4 and IPv6 to avoid this.
libssh
ssh_connect()connects to the first resolved address only, which for example means that for localhost, resolving to::1and127.0.0.1, it is only connecting to::1. If the service is not reachable on IPv6 on a dual-stack host, then the connection will fail.Can be reproduced with in the
dual-stackbranch in this repository running the interop test, or startingghcr.io/notconf/notconf:26146692186and running theacton test --tag notconf-serverin the netconf repo. This is an older version of notconf, I have since updated it to listen on both IPv4 and IPv6 to avoid this.