change: bypass resolver follows the physical network's DNS #97
Loading…
Reference in a new issue
No description provided.
Delete branch "change/bypass-follows-host-dns"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
#60: with #58 merged, the bypass dnsmasq's queries leave through the physical link — but they still go to the configured alternative servers (Quad9 by default), not whatever resolver the host would use with the VPN off. Bypassed apps got the wrong geo answers and no split-horizon unless the user pointed alt_dns at the LAN resolver by hand.
Fix
dns_manager.bypass_upstreams(interface, fallback_1, fallback_2): discovers the physical network's own DNS and returns the upstream pair, falling back to the alternative servers when nothing is discoverable. Discovery isphysical_dns(): under resolved, the link's own per-link DNS (existinglink_dns), then resolved's Global list; on resolv.conf systems, the/etc/resolv.conf.aqomui.bakbackup the service already takes at GUI start and on every network change — before any tunnel rewrites the live file.bypass()per network change, which kills and respawns dnsmasq, so discovery re-runs each time.#modified by aqomuimarker is not a source.Verification
physical_dns("enp5s0")returns the LAN resolver from the link's resolved config; a nonexistent interface logs and falls back to the alternative servers cleanly.Closes #60