Firefox doesn't handle *.localhost domains (loopback)
Categories
(Core :: Networking: DNS, defect, P3)
Tracking
()
People
(Reporter: thomas, Assigned: jkt)
References
Details
(Whiteboard: [necko-triaged])
Comment 1•7 years ago
|
||
Comment 3•7 years ago
|
||
Comment 4•7 years ago
|
||
Updated•6 years ago
|
Updated•6 years ago
|
Updated•6 years ago
|
Comment 6•5 years ago
|
||
I just tested current state of this issue:
Chrome 78 already handles *.localhost
domains and marks them as Secure Context.
Firefox 69 marks localhost
as Secure Context, but does not do the same for subdomains (marks foo.bar.localhost
as insecure).
Demo: https://ipfs.io/ipfs/bafybeifnnjo5dyw63fcg6o72jbksrn726hpilqgokdgm44al2v5oxmv2yu/localhost-subdomains
Fully agree with https://bugzilla.mozilla.org/show_bug.cgi?id=1433933#c3, and https://bugzilla.mozilla.org/show_bug.cgi?id=1433933#c4:
it's easier to update Firefox to match Chromium behaviour (and bind to 127.0.0.1
/::1
) than to rely on set up of custom DNS servers or HTTP proxies.
The use case I am interested in are HTTP Gateways for DWEB protocols, such as IPFS.
Having localhost subdomains working reliable in Firefox (as Secure Contexts) would enable IPFS project to provide Origin-based isolation of websites loaded from local HTTP Gateway (https://github.com/ipfs/in-web-browsers/issues/109 & https://github.com/ipfs/in-web-browsers/issues/89)
Comment 7•5 years ago
|
||
The current algorithm that Chromium uses: https://cs.chromium.org/chromium/src/net/base/url_util.cc?l=426&rcl=2aa5cab485d1d0360bad1bfec4aaea4242adcc8b
Updated•5 years ago
|
Assignee | ||
Comment 8•5 years ago
|
||
The uploaded patch in Bug 1220810 is attempting to address this also.
Assignee | ||
Updated•5 years ago
|
on Mac:
go to terminal
$ sudo nano /etc/localhosts
on Windows:
Click Start > All Programs > Accessories
Right-click Notepad and select Run as administrator.
In the File name field, type C:\Windows\System32\Drivers\etc\hosts.
click open
then
add aline at the end of the file your domain in front of 127.0.0.1 like the below:
127.0.0.1 yourDomain.localhost
save and exit.
Updated•5 years ago
|
Description
•