summaryrefslogtreecommitdiffhomepage
path: root/talpid-core/src/dns/linux
AgeCommit message (Collapse)AuthorFilesLines
2024-12-12Remove some deprecated ref patternsJoakim Hulthe1-15/+12
2024-11-28Log failure reason when trying DNS managersJoakim Hulthe1-14/+27
2024-09-18Keep separate tunnel state machine configs for tunnel and non-tunnel DNSDavid Lönnhager1-1/+4
2024-02-27Replace err_derive with thiserrorJoakim Hulthe4-35/+35
`err_derive` is unmaintained and will probably stop working with rust edition 2024. `thiserror` is almost a drop-in replacement. This commit simply replaces all occurences of `derive(err_derive::Error)` with `derive(thiserror::Error)` and fixes the attributes, but the Error and Display impls should be identical.
2023-09-11Fix warnings about static_resolv_confDavid Lönnhager1-4/+5
2023-08-30Fix clippy lintsEmīls2-16/+10
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-1/+1
2022-12-21Apply more clippy fixes.Emīls1-2/+2
2022-11-07Split up talpid-coreEmīls Piņķis3-8/+4
2022-09-27Fix clippy complaintsEmīls Piņķis1-1/+1
2022-06-29Remove notify dependency and add inotify insteadJonathan2-44/+69
Switch from notify to inotify since we only used notify on Linux. This helps cleanup our dependency tree and allows us to have more control over how the thread responsible for monitoring `resolv.conf` exits.
2022-06-21Fix the large majority of clippy warningsJonathan2-14/+14
This commit fixes most of the remaining clippy warnings in the codebase. These warnings were the more semantically difficult ones to fix. There are some warnings that remain from the rebase that will be fixed in the upcoming PR.
2022-06-14Manually fix the simpler non-semantic clippy warnsJonathan3-5/+6
This commit tries to manually fix the clippy warnings that are fairly straightforward and do not have rippling effects on the codebase nor have a very high chance of causing bugs.
2022-04-29Fix log about selecting NetworkManagerDavid Lönnhager1-1/+1
2022-01-11Use ": " as delimiter instead of " - " between messages and valueLinus Färnstrand1-2/+2
2021-11-29Reformat code without blank_lines_upper_bound = 2Linus Färnstrand3-5/+0
2021-11-05Remove unused DNS monitor argumentsDavid Lönnhager1-6/+2
2021-11-03Ignore local resolvers for systemd-resolvedEmīls Piņķis3-446/+26
2021-10-08Simplify cleanup in systemd resolved monitorDavid Lönnhager1-3/+1
2021-10-05Fix mutex/await warningDavid Lönnhager1-5/+13
2021-08-09Always disable DNS over TLS in systemd-resolvedEmīls1-0/+6
2021-06-22Use the route manager for the Linux offline monitorDavid Lönnhager1-1/+1
2021-06-22Use the route manager for route monitoring in the DNS monitorDavid Lönnhager3-145/+83
2021-06-09Fix D-Bus errors by using a separate connection for the route monitorDavid Lönnhager1-1/+1
2021-06-09Infer and monitor interfaces for DNS configDavid Lönnhager3-52/+506
2021-03-26Fix deadlock in systemd-resolvedEmīls1-50/+63
2021-03-02Watch DNS config changes in systemd-resolvedEmīls2-276/+76
Certain NM versions will overwrite systemd-resovled config when they're reapplying existing config, this can be invoked `nmcli general reload dns-full` or by receiving a new DHCP lease. NM will just wipe the config for interfaces it doesn't have the config for in systemd-resolved, and since our daemon prefers systemd-resolved over NM, our config would be wiped. To fix this, I've changed the systemd-resolved DNS code to listen to changes to the global DNS config and reapply the tunnel interface DNS config if it's changed in any way. To better seperate the conecrns, the systemd-resolved DBus specific code was moved to the `talpid-dbus` crate, and the DNS code that manages the state and applies changes remains in `talpid-core`. One other solution that was considered was to just prefer NM over systemd-resolved, and we already kind of could do that, but the coming NM versions (1.28 and up) seem to not be able to manage DNS via it's own /etc/resolv.conf.
2021-03-01Stop using NM if it's too newEmīls1-0/+1
2021-01-12Rely on talpid-dbus in talpid-coreEmīls2-7/+8
2021-01-07Match content of /etc/resolv.conf for systemd-resolvedEmīls1-11/+41
2020-12-15Add new resolve.conf path to check for systemd-resolvedEmīls1-11/+34
2020-11-19Simplify systemd-resolved codeEmīls1-5/+1
Since issues with NM managing DNS via systemd-resolved are fixed, it's no longer necessary to check if NM is actually using systemd-resolved before picking systemd-resolved to manage DNS. The end result of these changes is that the daemon fall back to using NM more often now, but it shouldn't be an issue.
2020-11-19Add shared DBus connectionEmīls1-4/+4
2020-11-19Refactor systemd-resolved DBus codeEmīls1-97/+70
2020-11-19Use refactored NM code for managing DNSEmīls2-485/+17
2020-11-19Refactor connectivity check disablingEmīls1-3/+4
2020-11-16Remove deprecated NetworkManager optionDavid Lönnhager1-15/+2
2020-11-13Allow obtaining a DBus connection from DNS monitorEmīls3-2/+10
2020-11-09Add search domain to NM DNS configEmīls1-0/+1
2020-11-09Always let DnsMonitor::reset succeed if it finds no interfaceDavid Lönnhager3-54/+72
2020-11-09Enable NM's WireGuard via an environment variableEmīls1-2/+0
2020-11-09Use netlink to create WireGuard device instead of NMEmīls2-25/+27
2020-11-05Prefer systemd-resolved over NM if it's workingEmīls2-10/+73
2020-11-04Don't log absence of systemd-resolved as an errorDavid Lönnhager1-2/+6
2020-11-04Fix device state checkDavid Lönnhager1-1/+1
2020-10-28Adjust NM DNS code for IPv6Emīls1-1/+5
2020-10-28Allow more device states with NM DNSEmīls1-22/+40
2020-09-22Upgrade dbus-rsDavid Lönnhager2-17/+23
2020-09-03Allow more systemd-resovled config pathsEmīls1-9/+19