Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
1 <html>
2 <head>
3 <title></title>
5 <script type="text/javascript">
7 var scriptItem = "untouched";
9 function checkLoads() {
10 // Make sure the javascript did not load.
11 window.parent.is(scriptItem, "untouched", "Should not load bad javascript");
13 // Make sure the css did not load.
14 var elt = document.getElementById("styleCheck");
15 var style = document.defaultView.getComputedStyle(elt, "");
16 window.parent.isnot(style.visibility, "hidden", "Should not load bad css");
18 // End (parent) test.
19 window.parent.SimpleTest.finish();
20 }
22 </script>
24 <!-- Try loading from a malware javascript URI -->
25 <script type="text/javascript" src="http://malware.example.com/tests/toolkit/components/url-classifier/tests/mochitest/evil.js"></script>
27 <!-- Try loading from a malware css URI -->
28 <link rel="stylesheet" type="text/css" href="http://malware.example.com/tests/toolkit/components/url-classifier/tests/mochitest/evil.css"></link>
30 <!-- XXX How is this part of the test supposed to work (= be checked)? -->
31 <!-- Try loading a marked-as-malware css through an @import from a clean URI -->
32 <link rel="stylesheet" type="text/css" href="import.css"></link>
33 </head>
35 <body onload="checkLoads()">
36 The following should not be hidden:
37 <div id="styleCheck">STYLE TEST</div>
38 </body>
39 </html>