tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

test_bug329869.html (1011B)


      1 <!DOCTYPE HTML>
      2 <html>
      3 <head>
      4  <title>dymanic script load</title>
      5  <script src="/tests/SimpleTest/SimpleTest.js"></script>
      6  <script type="text/javascript" src="mixedContentTest.js"></script>
      7  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
      8 
      9  <script class="testbody" type="text/javascript">
     10  "use strict";
     11 
     12  hasMixedActiveContent = true;
     13 
     14  async function runTest()
     15  {
     16    await isSecurityState("secure");
     17    window.setTimeout(function () {
     18      let newElement = document.createElement("script");
     19      newElement.src = "http://example.org/tests/security/manager/ssl/tests/" +
     20                       "mochitest/mixedcontent/bug329869.js";
     21      document.body.appendChild(newElement);
     22    }, 0);
     23  }
     24 
     25  async function afterNavigationTest()
     26  {
     27    await isSecurityState("secure", "when we navigate back, we're loading our secure page again and not loading an insecure script, so our security state is secure");
     28    finish();
     29  }
     30 
     31  </script>
     32 </head>
     33 
     34 <body>
     35 </body>
     36 </html>