Don't block mixed worker/WebSockets content from localhost
Categories
(Core :: DOM: Security, enhancement)
Tracking
()
People
(Reporter: poiru, Assigned: poiru)
References
Details
Attachments
(1 file)
Comment 1•7 years ago
|
||
Comment 2•7 years ago
|
||
Updated•7 years ago
|
Comment 3•7 years ago
|
||
Comment 4•7 years ago
|
||
Comment 6•6 years ago
|
||
Comment 7•5 years ago
|
||
We recently noticed that Firefox started blocking connectivity to WS on 127.0.0.1. This definitely works on Chrome - "localhost" is blocked, "127.0.0.1" but is working. Is this related and a deliberate change?
Comment 9•5 years ago
|
||
(In reply to pawel from comment #7)
We recently noticed that Firefox started blocking connectivity to WS on 127.0.0.1. This definitely works on Chrome - "localhost" is blocked, "127.0.0.1" but is working. Is this related and a deliberate change?
started blocking? I thought this bug (and bug 1488740) was requesting that we fix it, from the assumption that it was already not working in mid-2017. If something blocked it further it definitely wasn't an intentional change. Can you say which releases or builds worked and when it stopped working? Even better if you have a clear testcase/example.
bug 1402530 made changes to the mixed content blocker that would have been released as Firefox 68 this week. If anything it was intended to make this work better, not break it. Although I see tests added for "http://localhost" there may not have been ws: mixed-content tests.
Comment 10•5 years ago
|
||
(In reply to Daniel Veditz [:dveditz] OOO until 7/15 from comment #9)
Can you say which releases or builds worked and when it stopped working? Even better if you have a clear testcase/example. bug 1402530 made changes to the mixed content blocker that would have been released as Firefox 68 this week. If anything it was intended to make this work better, not break it. Although I see tests added for "http://localhost" there may not have been ws: mixed-content tests.
I just tested this on Firefox 68.0. Here's a test to reproduce I used:
- Fiddle to verify connectivity via WebSocket (it talks to 127.0.0.1:8080) - https://jsfiddle.net/47ny0xoa/
- Simple WebSocket echo server to run on 127.0.0.1:8080 - I used this one: https://github.com/pbadenski/simple-websocket-echo-server
Once a WebSocket server is running on your machine, jsfiddle should be able to connect to it. This works on Chrome (75.0.3770.100), but doesn't on Firefox. On firefox I get "SecurityError: The operation is insecure."
BTW Chrome also allows communication on "localhost" - which I wouldn't necessarily expect... but just mentioning for the sake of completeness.
Hope it helps...
Comment 11•5 years ago
|
||
I just used my test to verify Firefox 50 and Firefox 52 (random old versions I have) and this also doesn't seem to be working.
For clarification we did not do very thorough testing on Firefox beforehand for our WebSocket service, so it is likely that this was not working before as well.
Apologies for confusion.
Assignee | ||
Comment 12•5 years ago
|
||
We already allow HTTPS origins to use to plain HTTP active content when using
loopback URLs such as http://127.0.0.1. Lets extend this to WebSocket
connections as well to match Chrome.
Assignee | ||
Updated•5 years ago
|
Updated•5 years ago
|
Comment 13•5 years ago
|
||
Assignee | ||
Comment 14•5 years ago
|
||
Marking leave-open because I didn't check if this is fixed for workers yet.
Comment 15•5 years ago
|
||
bugherder |
Comment 16•5 years ago
|
||
The leave-open keyword is there and there is no activity for 6 months.
:ckerschb, maybe it's time to close this bug?
Comment 17•5 years ago
|
||
Removing priority so it shows up in our triage meeting tonight. I'll discuss with folks but I guess we can simply mark it as fixed. Question is just for what version for Firefox :-)
Updated•5 years ago
|
Comment 18•5 years ago
|
||
in-testsuite? flag to cover landing tests for comment 14, but the bug itself appears fixed.
Updated•5 years ago
|
Description
•