summaryrefslogtreecommitdiffhomepage
path: root/talpid-routing/src
diff options
context:
space:
mode:
authorMarkus Pettersson <markus.pettersson@mullvad.net>2024-02-02 16:14:53 +0100
committerMarkus Pettersson <markus.pettersson@mullvad.net>2024-02-09 13:04:06 +0100
commita6a26bf92ddd690c85e7cefbca1c8e5bb7fe7683 (patch)
treeea5b784ceca66b772e8065ce6686a9cefdc3faeb /talpid-routing/src
parent7fe5f5fe63621a448623ee53c651ed2dd50b9d4a (diff)
downloadmullvadvpn-a6a26bf92ddd690c85e7cefbca1c8e5bb7fe7683.tar.xz
mullvadvpn-a6a26bf92ddd690c85e7cefbca1c8e5bb7fe7683.zip
Detect available IP versions
Try to detect available IP versions by looking at the available routes on the host. On Linux, we check if there exists IPv4 and/or IPv6 routes to some public IP addresses. On macOS and Windows, we check if there exists default routes for IPv4 and/or IPv6. On Android, we check if there is any connectivity at all. The intention is to be able to generate better default constraints for tunnel endpoints. If we can detect "working" IPv4 and/or IPv6 and forward this information to a `TunnelParametersGenerator`, we may choose to connect to a Wireguard relay using IPv6 as part of our retry-strategy. This has not been possible before.
Diffstat (limited to 'talpid-routing/src')
-rw-r--r--talpid-routing/src/lib.rs4
1 files changed, 1 insertions, 3 deletions
diff --git a/talpid-routing/src/lib.rs b/talpid-routing/src/lib.rs
index 0801807598..d525b12435 100644
--- a/talpid-routing/src/lib.rs
+++ b/talpid-routing/src/lib.rs
@@ -25,9 +25,7 @@ use netlink_packet_route::rtnl::constants::RT_TABLE_MAIN;
#[cfg(target_os = "macos")]
pub use imp::{imp::RouteError, DefaultRouteEvent, PlatformError};
-pub use imp::{Error, RouteManager};
-
-pub use imp::RouteManagerHandle;
+pub use imp::{Error, RouteManager, RouteManagerHandle};
/// A network route with a specific network node, destination and an optional metric.
#[derive(Debug, Hash, Eq, PartialEq, Clone)]