Closed Bug 1467721 Opened 8 years ago Closed 8 years ago

navigation is overridden by changing location.href in WebSocket.onclose()

Categories

(Core :: DOM: Navigation, defect)

61 Branch
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 1343331

People

(Reporter: bacon_forest, Unassigned)

Details

Attachments

(1 file)

Attached file poc.html
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:60.0) Gecko/20100101 Firefox/60.0 Build ID: 20180605171542 Steps to reproduce: 1. In Firefox, open the attached html file which includes the following script: const socket = new WebSocket('ws://example.net'); socket.onclose = function () { location.href = location.href }; 2. try to go to a new page (e.g., clicking bookmark items, typing a URL in address bar or clicking <a> tag) Actual results: Navigation is overridden by "location.href = <URL>" in WebSocket.onclose(). If <URL> is location.href, Firefox reopens the current page. Expected results: Firefox should open the new page.
Not a severe enough issue to keep hidden, and a duplicate of public bug 1343331, so marking as such.
Group: firefox-core-security
Status: UNCONFIRMED → RESOLVED
Closed: 8 years ago
Resolution: --- → DUPLICATE
Component: Untriaged → Document Navigation
Product: Firefox → Core
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: