summaryrefslogtreecommitdiffhomepage
path: root/talpid-routing/src/lib.rs
AgeCommit message (Collapse)AuthorFilesLines
2025-10-24Integrate GotaTun cleanlyMarkus Pettersson1-1/+1
Refactor `trait Tunnel` and factor `start_daita` into `set_config`. Co-authored-by: Joakim Hulthe <joakim.hulthe@mullvad.net>
2025-09-17Upgrade rtnetlink libs to latest versionMarkus Pettersson1-4/+1
Signed-off-by: Markus Pettersson <markus.pettersson@mullvad.net>
2025-09-08Refactor and document macOS route socket typesDavid Lönnhager1-1/+1
2025-07-10Run `cargo fmt`Sebastian Holmin1-2/+2
2025-06-05Fix typosomahs1-1/+1
2025-02-06Replace old waitForTunnelUp functionDavid Göransson1-1/+33
After invoking VpnService.establish() we will get a tunnel file descriptor that corresponds to the interface that was created. However, this has no guarantee of the routing table beeing up to date, and we might thus send traffic outside the tunnel. Previously this was done through looking at the tunFd to see that traffic is sent to verify that the routing table has changed. If no traffic is seen some traffic is induced to a random IP address to ensure traffic can be seen. This new implementation is slower but won't risk sending UDP traffic to a random public address at the internet.
2024-04-30Add initial split tunneling implementation for macOSDavid Lönnhager1-0/+41
2024-04-22Fix broken lints in rustdocsSebastian Holmin1-1/+1
I ran `cargo doc` and fixed as many broken links as I could find.
2024-03-18Make burst guard publicDavid Lönnhager1-1/+2
2024-03-14Simplify route manager handleDavid Lönnhager1-3/+3
2024-02-09Detect available IP versionsMarkus Pettersson1-3/+1
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.
2024-01-25Set default route MTU when using multihop on macOS. This prevents fragmentationDavid Lönnhager1-5/+5
2024-01-15Reconnect if default route disappears while connecting on macOSDavid Lönnhager1-1/+1
2024-01-04Add workspace level lintsLinus Färnstrand1-1/+0
2023-12-04Subtract multihop overhead from default route MTU on LinuxDavid Lönnhager1-0/+20
2023-10-05Coalesce route events in macOS route monitorDavid Lönnhager1-1/+1
2023-10-05Move debounce logic out of windows modDavid Lönnhager1-0/+3
2023-06-05Rework macOS routingDavid Lönnhager1-4/+1
2023-06-05Attempt to setup routes the other wayEmīls1-1/+4
2023-05-24Restructure routing modules to be hierarchicalLinus Färnstrand1-1/+2
2023-03-27Fix many typosAlexander Seiler1-1/+1
Signed-off-by: Alexander Seiler <seileralex@gmail.com>
2023-01-30Run `cargo clippy --fix` with the new Rust 1.67 preferred formatLinus Färnstrand1-2/+2
2022-11-07Refactor routing codeEmīls Piņķis1-4/+5
Simplify routing to abstract some of the platform specific details
2022-11-07Split up talpid-coreEmīls Piņķis1-0/+180