Closed Bug 196291 Opened 22 years ago Closed 22 years ago

Non-critical blocked JavaScript functions such as Window.focus should only generate a warning or be ignored, rather than an error

Categories

(Core :: Security: CAPS, defect)

defect
Not set
normal

Tracking

()

VERIFIED DUPLICATE of bug 122866

People

(Reporter: Bugzilla08, Assigned: security-bugs)

Details

User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.3) Gecko/20030303 Build Identifier: Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.3) Gecko/20030303 When viewing a web page that uses a blocked JavaScript function like Window.focus(), it generates an error (in the JavaScript console) and stops the remainder of the script from executing. For pages that generate the content of the page via script after that point, it means that content is not displayed, even though there is no reason the script could not be allowed to continue. This happens to me using an 'ensim' web hosting control panel. When you perform a function it has a 'details' link (for information such as errors that occured). Clicking that pops up a window, does a Window.focus(), then writes the details. Blocked critical JavaScript commands such as Window.open() do need to produce and error and stop execution since there is no window to perform further actions on. But functions that only have cosmetic effect (focus, blur, resizing, moving) should allow the script to continue (with a possible warning displayed in the console). I can't give a url since it's a password limited page, but could produce a sample page of my own if needed. But I think the concept should be fairly straight forward, and hopefully minor to adjust for. Reproducible: Always Steps to Reproduce: 1. Disable JavaScripts from "Raise or lower windows" in prefs. 2. View a page that tries to Window.focus() before writting its output. Actual Results: The page was blank. Expected Results: The page should have displayed the details written by the script after the Window.focus() command.
*** This bug has been marked as a duplicate of 122866 ***
Status: UNCONFIRMED → RESOLVED
Closed: 22 years ago
Resolution: --- → DUPLICATE
v
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.