tor-browser

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

postmessage-entry.html (453B)


      1 <!doctype html>
      2 <script>
      3 addEventListener("load", () => {
      4  const entry = performance.getEntriesByType("navigation")[0];
      5  try {
      6    window.top.postMessage(entry, "*");
      7  } catch(error) {
      8    if (error.name == "DataCloneError") {
      9      window.top.postMessage("PASS", "*");
     10    } else {
     11      window.top.postMessage("FAIL - Wrong exception name: " + error.name, "*");
     12    }
     13  }
     14  window.top.postMessage("FAIL - No exception thrown", "*");
     15 });
     16 
     17 </script>