Merge pull request #997 from taziden/patch-2

fix v6 detection when using wg-quick
This commit is contained in:
Alexandre Aubin 2020-05-21 18:02:22 +02:00 committed by GitHub
commit a1cba8b6fa
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -108,7 +108,7 @@ class IPDiagnoser(Diagnoser):
return False return False
# If we are indeed connected in ipv4 or ipv6, we should find a default route # If we are indeed connected in ipv4 or ipv6, we should find a default route
routes = check_output("ip -%s route" % protocol).split("\n") routes = check_output("ip -%s route show table all" % protocol).split("\n")
def is_default_route(r): def is_default_route(r):
# Typically the default route starts with "default" # Typically the default route starts with "default"

View file

@ -57,7 +57,7 @@ def get_public_ip_from_remote_server(protocol=4):
return None return None
# If we are indeed connected in ipv4 or ipv6, we should find a default route # If we are indeed connected in ipv4 or ipv6, we should find a default route
routes = check_output("ip -%s route" % protocol).split("\n") routes = check_output("ip -%s route show table all" % protocol).split("\n")
def is_default_route(r): def is_default_route(r):
# Typically the default route starts with "default" # Typically the default route starts with "default"
# But of course IPv6 is more complex ... e.g. on internet cube there's # But of course IPv6 is more complex ... e.g. on internet cube there's