Firefox bypasses system DNS lookup
Categories
(Core :: Networking: DNS, defect)
Tracking
()
People
(Reporter: carls, Unassigned)
Details
Attachments
(2 files)
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:84.0) Gecko/20100101 Firefox/84.0
Steps to reproduce:
- Add (block) twitter.com to /etc/hosts:
0.0.0.0 twitter.com - Surf to https://twitter.com
I have cleared the cache and restarted Firefox.
I have disabled DNS over HTTPS.
Chromium as well as dig and nslookup correctly reports the failed lookup.
Actual results:
Twitter's login page loads
Expected results:
A DNS lookup error should be presented
Comment 2•5 years ago
|
||
Have you disabled DNS over https? https://support.mozilla.org/en-US/kb/firefox-dns-over-https
Comment 3•5 years ago
|
||
The Bugbug bot thinks this bug should belong to the 'Core::Networking: DNS' component, and is moving the bug to that component. Please revert this change in case you think the bot is wrong.
(In reply to Robert Longson [:longsonr] from comment #2)
Have you disabled DNS over https? https://support.mozilla.org/en-US/kb/firefox-dns-over-https
Yes, DNS over HTTPS is disabled.
Comment 5•5 years ago
|
||
I can't reproduce this, so could you try to get the http log?
Thanks.
Comment 6•5 years ago
|
||
Hi Carl, thank you for the report.
Adding an entry to /etc/hosts should prevent us from using TRR - see bug 1616252
But maybe there is a bug in the implementation.
Could you post the contents of about:support here along with a HTTP log?
https://developer.mozilla.org/en-US/docs/Mozilla/Debugging/HTTP_logging
If possible, use a separate profile with no extensions.
Thanks!
| Reporter | ||
Comment 10•5 years ago
|
||
(In reply to Valentin Gosu [:valentin] (he/him) from comment #6)
Hi Carl, thank you for the report.
Adding an entry to /etc/hosts should prevent us from using TRR - see bug 1616252
But maybe there is a bug in the implementation.Could you post the contents of about:support here along with a HTTP log?
https://developer.mozilla.org/en-US/docs/Mozilla/Debugging/HTTP_logging
If possible, use a separate profile with no extensions.Thanks!
Hmm, I can't reproduce it with another profile.
The only extension I've otherwise got running is uBlock Origin.
I've created logs for both profiles and if I'm reading them correctly, in both cases twitter.com resolves to 0.0.0.0
I have attached logs from both profiles and about:support from my own profile.
Comment 11•5 years ago
|
||
If I'm looking at the correct place in the log it seems that twitter is being loaded from the cache.
You can check this by clearing the HTTP cache.
Go to History -> Clear recent history -> Make sure that Cache is checked -> Clear
Note: be careful with what other boxes are checked if you care about preserving your browsing history.
Thanks!
| Reporter | ||
Comment 12•5 years ago
|
||
(In reply to Valentin Gosu [:valentin] (he/him) from comment #11)
If I'm looking at the correct place in the log it seems that twitter is being loaded from the cache.
You can check this by clearing the HTTP cache.
Go to History -> Clear recent history -> Make sure that Cache is checked -> Clear
Note: be careful with what other boxes are checked if you care about preserving your browsing history.Thanks!
I've tried clearing the cache and offline website data multiple times but the problem persists.
If I look in the cache directory, I can see there's a bunch of stuff still left there after clearing it, including several twitter logos and graphics from their login site.
Comment 13•5 years ago
|
||
Ah, I think I know what's going on here.
It's probably caused by the service worker.
It got registered before you added the /etc/hosts rule, then it gets loaded even when you clear the cache.
Could you check if going to about:serviceworkers and clicking unregister for the twitter worker fixes the issue? It should be unable to load after that.
| Reporter | ||
Comment 14•5 years ago
|
||
That's the ticket, works as expected now. Thanks!
Comment 15•5 years ago
|
||
Thanks for looking into this. Cheers!
Description
•