Local servers (with local/private 172.x ip addresses) can't be accessed here from android phones.
Does not work:
Access any local host via hostname.
Access a internet host for which the hostname is configured locally (openwrt hosts) only.
(This is why I assume that my local openwrt-DNS is eventually queried. But android does not seem to like if the ip addresses are local/private then)
Access local host via ip address.
Access anything from any other system (Linux and Windows, Firefox, Chrome, Filebrowser, ping, ssh, ...)
I found other discussions (not this forum). Often it is assumed that android sends everything to google via DNS over HTTPS. This does not seem to be the case here as it works with "local" hostnames with public ip addresses.
There is also mDNS...
To be honest, I am also a bit confused now. Not sure when which type of DNS resolution is expected to run.
I could not even figure out whether openwrt should run mDNS service (I do assume that it does not).
From my point of view there are two possible options to solve this:
- Configure my openwrt box to force android clients to use the local DNS always and to trust it also for local/private ip addresses.
- Force android to use the local DNS always (only in my local Wifi?) by do some configurations.
Many Thanks for any hints
Hm. Not sure what to make of this.
On the one hand, this seems to be somehow related. There were many assumptions and it is unsure what happend when. After all, it was the app that seems to have the queries to some mircosoft server hardcoded..
By the way: In my case we know that Android does query the local DNS (at least in general). But it does just not seem to like answers with private ip addresses.
I am hijacking the queries from the lan and redirect them to my Piholes. Internal FQDNs are resolved properly from the Piholes. This can be applied too for the dnsmasq as nameserver.
It should actually be necessary to hijack DNS queries? This does really feel wrong.
If this is necessary, Android is actually seriously broken.
This would eventually mean that companies, organisations and hotels ... using private addresses in their local network could not use Android devices to access local services.
It is not working properly by bypassing the assigned nameservers from the DHCP and preferring the GoogleDNS.
But if it is bypassing the the assigned name-server, why does my Android phone successfully resolve a public host that is configured locally only?
This can work if it is not bypassing my local DNS only.
For instance. I configure "abcdef.abcdef" -> 18.104.22.168
Then I use Firefox on the Android device and type adcdef.abcdef -> reaching google (ok, states "URL / not found, but DNS works!).
I don't know. Setup a packet capture with tcpdump and we'll find out.