Skip to content

android: route device DNS through the awldns interceptor - #38

Merged
pymq merged 1 commit into
masterfrom
awldns-android
Jul 25, 2026
Merged

pymq merged 1 commit into
masterfrom
awldns-android

Conversation

@pymq

@pymq pymq commented Jul 23, 2026

Copy link
Copy Markdown
Member

For anywherelan/awl#264
For anywherelan/awl#17

The awl core now runs a DNS interceptor on an in-tunnel IP, so .awl names resolve inside the tunnel on Android too. Point the VpnService at it.

establishTun: when DNS is enabled, addDnsServer(Anywherelan.dnsServerIP()) so all device DNS reaches the interceptor. An empty string (no free IP, or the core couldn't bring it up) means add nothing. The old addDnsServer(upstream) pin now survives only as a fallback for the DNS-disabled + gateway case, to avoid leaking DNS in full-tunnel mode.

AppConfig parses dns.disableDNS (forward-compatible) — the kill switch.

The awl core now runs a DNS interceptor on an in-tunnel IP, so .awl names resolve inside the tunnel on Android too. Point the VpnService at it.

establishTun: when DNS is enabled, addDnsServer(Anywherelan.dnsServerIP()) so all device DNS reaches the interceptor. An empty string (no free IP, or the core couldn't bring it up) means add nothing. The old addDnsServer(upstream) pin now survives only as a fallback for the DNS-disabled + gateway case, to avoid leaking DNS in full-tunnel mode.

AppConfig parses dns.disableDNS (forward-compatible) — the kill switch.
@pymq
pymq merged commit 6935d59 into master Jul 25, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant