tor-browser

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

inline-style-attribute-blocked.sub.html (970B)


      1 <!DOCTYPE html>
      2 <html>
      3 
      4 <head>
      5    <!-- Programmatically converted from a WebKit Reftest, please forgive resulting idiosyncracies.-->
      6    <meta http-equiv="Content-Security-Policy" content="style-src 'none'; script-src 'self' 'unsafe-inline' 'unsafe-inline'; connect-src 'self';">
      7    <title>inline-style-attribute-blocked</title>
      8    <script src="/resources/testharness.js"></script>
      9    <script src="/resources/testharnessreport.js"></script>
     10    <script src='../support/logTest.sub.js?logs=["violated-directive=style-src-attr","PASS"]'></script>
     11    <script src="../support/alertAssert.sub.js?alerts=[]"></script>
     12    <script>
     13       window.addEventListener('securitypolicyviolation', function(e) {
     14            log("violated-directive=" + e.violatedDirective);
     15       });
     16    </script>
     17 </head>
     18 <body style="background-color: blue;">
     19 
     20    <script>
     21        log(document.body.style.length > 0 ? 'FAIL' : 'PASS');
     22 
     23    </script>
     24    <div id="log"></div>
     25 </body>
     26 
     27 </html>