You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm updating magic-wormhole to use the new txtorcon APIs, and I noticed one difference between the _is_non_public_numeric_address() function in txtorcon and the one in magic-wormhole that inspired it. The magic-wormhole one checks for a.version != 4, to skip IPv6 addresses.
Should this be added to txtorcon?
diff --git a/txtorcon/controller.py b/txtorcon/controller.py
index 61b6ac2..f534ae3 100644
--- a/txtorcon/controller.py
+++ b/txtorcon/controller.py
@@ -663,7 +663,7 @@ def _is_non_public_numeric_address(host):
except ValueError:
return False # non-numeric, let Tor try it
if a.is_loopback or a.is_multicast or a.is_private or a.is_reserved \
- or a.is_unspecified:
+ or a.is_unspecified or a.version != 4:
return True # too weird, don't connect
return False
The text was updated successfully, but these errors were encountered:
I'm updating magic-wormhole to use the new txtorcon APIs, and I noticed one difference between the
_is_non_public_numeric_address()
function in txtorcon and the one in magic-wormhole that inspired it. The magic-wormhole one checks fora.version != 4
, to skip IPv6 addresses.Should this be added to txtorcon?
The text was updated successfully, but these errors were encountered: