Closed Bug 377069 Opened 18 years ago Closed 18 years ago

Javascript can close browser window without confirmation

Categories

(Firefox :: Security, defect)

x86
Windows XP
defect
Not set
critical

Tracking

()

RESOLVED DUPLICATE of bug 212298

People

(Reporter: joe, Unassigned)

Details

Attachments

(1 file)

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; hu; rv:1.8.0.11) Gecko/20070312 Firefox/1.5.0.11 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; hu; rv:1.8.0.11) Gecko/20070312 Firefox/1.5.0.11 Specially crafted javascript closes the current tab/window without any notification: <script language=javascript> window.open('','_parent',''); window.close(); </script> Window names _parent, _top, _self can close the current page. Reproducible: Always Steps to Reproduce: Just open a html file which contains the above JS snippet. Actual Results: 1. Current tab closed. 2. Only one tab -> browser closed. Expected Results: blocking, confirmation, warning, etc.
I'm unable to reproduce this with the given testcase in Firefox 2 or 3.0a3. Joe, can you retest in Firefox 2?
DUP of Bug 266371? See also bugs in dependency tree and DUPs of them.
Maybe not exactly, but I'll try…
Status: UNCONFIRMED → RESOLVED
Closed: 18 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: