4 https://bugzilla.mozilla.org/show_bug.cgi?id=423375
7 <title>Test for Bug
423375</title>
8 <script type=
"text/javascript" src=
"/MochiKit/MochiKit.js"></script>
9 <script type=
"text/javascript" src=
"/tests/SimpleTest/SimpleTest.js"></script>
10 <link rel=
"stylesheet" type=
"text/css" href=
"/tests/SimpleTest/test.css" />
13 <a target=
"_blank" href=
"https://bugzilla.mozilla.org/show_bug.cgi?id=423375">Mozilla Bug
423375</a>
15 <div id=
"content" style=
"display: none">
16 <iframe id=
"load-frame"></iframe>
19 <script class=
"testbody" type=
"text/javascript">
22 ** Test for Bug
423375
23 ** (content shouldn't be able to load chrome: or resource:)
28 window.frames[
0].location = url;
30 } catch (e if /Access.*denied/.test(String(e))) {
33 return
"unexpected: " + e;
37 is(tryLoad(
"chrome://global/content/mozilla.xhtml"),
"denied",
38 "content should have been prevented from loading chrome: URL");
39 is(tryLoad(
"resource://gre/res/html.css"),
"denied",
40 "content should have been prevented from loading resource: URL");