tor-browser

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

coop-noopener-allow-popups.https.html (2222B)


      1 <!doctype html>
      2 <meta name="timeout" content="long">
      3 <title>
      4    Cross-Origin-Opener-Policy: noopener-allow-popups means that the opener
      5    has no access to the openee.
      6 </title>
      7 <script src="/resources/testharness.js"></script>
      8 <script src="/resources/testharnessreport.js"></script>
      9 <script src="/common/dispatcher/dispatcher.js"></script>
     10 <script src="/common/get-host-info.sub.js"></script>
     11 <script src="/common/utils.js"></script>
     12 <script src="./resources/common.js"></script>
     13 <script src="./resources/noopener-helper.js"></script>
     14 <script>
     15 
     16 
     17 test_noopener_opening_popup("noopener-allow-popups",
     18                            "unsafe-none",
     19                            SAME_ORIGIN,
     20                            /*opener_expectation=*/true);
     21 test_noopener_opening_popup("noopener-allow-popups",
     22                            "noopener-allow-popups",
     23                            SAME_ORIGIN,
     24                            /*opener_expectation=*/false);
     25 test_noopener_opening_popup("noopener-allow-popups",
     26                            "same-origin",
     27                            SAME_ORIGIN,
     28                            /*opener_expectation=*/false);
     29 test_noopener_opening_popup("noopener-allow-popups",
     30                            "same-origin-allow-popups",
     31                            SAME_ORIGIN,
     32                            /*opener_expectation=*/false);
     33 test_noopener_opening_popup("noopener-allow-popups",
     34                            "same-origin-allow-popups",
     35                            CROSS_ORIGIN,
     36                            /*opener_expectation=*/false);
     37 test_noopener_opening_popup("same-origin-allow-popups",
     38                            "noopener-allow-popups",
     39                            SAME_ORIGIN,
     40                            /*opener_expectation=*/false);
     41 test_noopener_opening_popup("same-origin",
     42                            "noopener-allow-popups",
     43                            SAME_ORIGIN,
     44                            /*opener_expectation=*/false);
     45 test_noopener_opening_popup("unsafe-none",
     46                            "noopener-allow-popups",
     47                            SAME_ORIGIN,
     48                            /*opener_expectation=*/false);
     49 test_noopener_navigating_away("unsafe-none");
     50 </script>