javascript-url-navigation-evaluated-to-string-inherits-csp.html (878B)
1 <!DOCTYPE html> 2 <link rel="help" href="https://html.spec.whatwg.org/multipage/browsing-the-web.html#evaluate-a-javascript:-url"> 3 <script src="/resources/testharness.js"></script> 4 <script src="/resources/testharnessreport.js"></script> 5 6 <script> 7 var window_url = encodeURIComponent("javascript:'<iframe src=/content-security-policy/support/fail.js></iframe>'"); 8 var report_cookie_name = encodeURIComponent("javascript-url-navigation-evaluated-to-string-inherits-csp"); 9 window.open("support/test_csp_self_window.sub.html?window_url=" + window_url + "&report_cookie_name=" + report_cookie_name); 10 setTimeout(function() { 11 var s = document.createElement('script'); 12 s.async = true; 13 s.defer = true; 14 s.src = "../support/checkReport.sub.js?reportField=violated-directive&reportValue=frame-src%20%27none%27"; 15 document.body.appendChild(s); 16 }, 2000); 17 </script>