DoH used even with NXDOMAIN response to canary domain
Categories
(Core :: Networking: DNS, defect, P2)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox85 | --- | fixed |
People
(Reporter: astrothayne, Assigned: valentin)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:79.0) Gecko/20100101 Firefox/79.0
Steps to reproduce:
I configured my DNS server to return NXDOMAIN for use-application-dns.net, as described athttps://support.mozilla.org/en-US/kb/canary-domain-use-application-dnsnet
I DID NOT manually enable Application DNS/DoH (athough really, there shouldn't be a difference between automatically enabling DNS/DoH and manually enabling it, or at least there should be an option to "use application DNS unless the canary domain indicates I shouldn't")
Actual results:
Firefox used application DNS with cloudflare instead of my custom (company) DNS server, resulting in incorrect DNS responses.
Expected results:
Firefox should use my configured DNS server rather than Cloudflare's DNS servers.
Updated•6 years ago
|
| Assignee | ||
Comment 1•6 years ago
|
||
Thank you for your report.
It's not clear as to why this would happen. Could you please attach the output you get when you navigate to about:support ? I'm curious about the value of the network.trr.mode pref. You can also get it by going to about:config and looking for that pref.
Also take a look at about:telemetry#events-tab There should be a bunch of doh-rollout events there. I'm curious as to what they say.
Thanks!
my network.trr.mode is currently 5, but I have since manually disabled DoH, because it was preventing me from connecting to internal sites. I could try to reproduce, however I'm not sure how to get back into the state I was in.
I also don't see any doh-rollout events in my `about:telemetry#events-tab. Possibly since I've restarted my computer since I disabled DoH?
| Assignee | ||
Comment 3•6 years ago
|
||
If you've made any changes to any TRR settings or prefs then the doh-rollout heuristics will be disabled (they assume you know if you want to use DoH or not). In that case the canary domain will not be queried.
I understand that. I had not made any changes when I encountered this bug. But have since manually disabled DoH, because it was causing me problems. But since I have made a change, I don't know how to go back to the heuristics mode, and therefore can no longer reproduce.
This is the order things happened in:
- I got a new laptop and installed firefox
- I got the notification about DoH and I selected "Got it", thinking this would keep me in heuristics mode. I also partly chose this, because I know this is most likely what other employees will select, and I have had complaints from other employees that use Firefox, that DoH was preventing them from accessing internal sites.
- I noticed that the canary domain was not being respected.
- I manually disabled DoH, because I need to get work done.
I am not the only one at my company that has run into this problem.
If you can provide instructions on how to reset the doh-rollout so I am in heuristics mode again, I would be happy to try to reproduce and provide more information.
| Assignee | ||
Comment 5•6 years ago
|
||
Thanks for the clarification.
The easiest way would be to create a new profile and try with that one. [1]
Once you do that, and you confirm that this is reproducible, restart Firefox and try to gather some logs using the instructions at [2]
[1] https://developer.mozilla.org/en-US/docs/Mozilla/Firefox/Multiple_profiles
[2] https://developer.mozilla.org/en-US/docs/Mozilla/Debugging/HTTP_logging
Thanks!
Hmm, I can't reproduce with a new profile. I wonder if it has something to do with the fact that the profile I saw this with was synced with my firefox account? Are about:config settings or doh rollout settings synced between browsers at all?
| Assignee | ||
Comment 7•6 years ago
|
||
To my knowledge doh-rollout prefs are not synced. Nihanth, can you confirm?
Comment 8•6 years ago
|
||
(In reply to Valentin Gosu [:valentin] (he/him) from comment #7)
To my knowledge doh-rollout prefs are not synced. Nihanth, can you confirm?
That's correct! DoH prefs are not included in Sync. You can see what prefs are included by filtering about:config for services.sync.prefs.sync. (each sync'd pref has a corresponding entry that starts with that prefix, IIUC).
Comment 9•6 years ago
|
||
Can you still reproduce this? If yes, it'd be great if you can help to get some logs.
Thanks.
| Reporter | ||
Comment 10•6 years ago
|
||
Unfortunately, I haven't been able to reproduce this anymore. It's possible I did something to get me into that state, but I don't know what.
Another possibility is that I may have temporarily entered a state where I was using DNS servers that didn't respond with NXDOMAIN for the canary domain. Like if I was temporarily disconnected from my VPN. If the heuristics determined that it should use DoH, would that ever persist even if the DNS servers change?
| Assignee | ||
Comment 11•6 years ago
|
||
Thanks for the info. Please keep an eye out for this in case it happens again.
Cheers!
| Reporter | ||
Comment 12•5 years ago
|
||
This may still be an issue. Several employees at my company are reporting issues with DNS not working as expected on our VPN when using Firefox, and I suspect DoH is to blame. I will see if I can gather more information.
| Reporter | ||
Comment 13•5 years ago
|
||
There has been at least one other employee who ran into this problem when he initially was not on the VPN (thus not getting NXDOMAIN responses for the canary domain) and then continued to get incorrect dns responses after he connected the VPN (and was thus getting NXDOMAIN response for the canary domain).
| Assignee | ||
Comment 15•5 years ago
|
||
(In reply to Thayne from comment #12)
This may still be an issue. Several employees at my company are reporting issues with DNS not working as expected on our VPN when using Firefox, and I suspect DoH is to blame. I will see if I can gather more information.
Ah, I see. So what I suspect is going on is the following:
- User resolves names using DoH
- User connects to VPN
- Network change clears regular Do53 cache, but not DoH cache
- DNS resolution finds entry in the cache and returns bad result.
It's not clear if this is the exact use case encountered by the reporter, but possibly related. Without logs to confirm I'll assume this is the problem and try to find a fix.
| Assignee | ||
Comment 16•5 years ago
|
||
This is necessary in order to avoid using cached entries on a network where
they might not be valid (such as when using a VPN).
This might not fix things when turning on the VPN does not cause a network
change event and thus no network.trr.mode/doh-rollout.mode change actually
happens.
Comment 17•5 years ago
|
||
Comment 18•5 years ago
|
||
Backed out for xpcshell failure on test_trr.js
Backout link: https://hg.mozilla.org/integration/autoland/rev/ab82da735f6c6cecabf08d7eef7388140a454763
Log link: https://treeherder.mozilla.org/logviewer?job_id=322863673&repo=autoland&lineNumber=4169
| Assignee | ||
Comment 19•5 years ago
|
||
I fixed the failure on the socket process run by also syncing doh-rollout.* prefs into the socket process - which is something we should have been doing all along.
Comment 20•5 years ago
|
||
Comment 21•5 years ago
|
||
| bugherder | ||
Description
•