From c8b8c275fa552b6205c6a84aa16053edd395af3c Mon Sep 17 00:00:00 2001 From: xyzconstant <263061129+xyzconstant@users.noreply.github.com> Date: Mon, 1 Jun 2026 18:54:01 -0300 Subject: [PATCH] test: Improve loopback address check in `rcp_bind.py` A loopback address can range from `127.0.0.0` to `127.255.255.255`. This commit relaxes the loopback check in `rpc_bind.py` by checking whether an IP address (from `all_interfaces()`) starts with `'127.'` instead of strictly matching `'127.0.0.1'`. Programs like VPNs might add an extra loopback address (e.g., 127.1.130.83), which failed under the previous state. These addresses will now pass with this update. --- test/functional/rpc_bind.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/functional/rpc_bind.py b/test/functional/rpc_bind.py index 422783510be..517df5d9c3f 100755 --- a/test/functional/rpc_bind.py +++ b/test/functional/rpc_bind.py @@ -109,7 +109,7 @@ class RPCBindTest(BitcoinTestFramework): raise AssertionError("all_interfaces() returned no IPv4 interfaces") self.non_loopback_ip = None for name,ip in interfaces: - if ip != '127.0.0.1': + if not ip.startswith('127.'): self.non_loopback_ip = ip break if self.non_loopback_ip is None and self.options.run_nonloopback: