tor-browser

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

about-blank-replacement-uncontrolled-nested-frame.html (598B)


      1 <!doctype html>
      2 <html>
      3 <body>
      4 <script>
      5 function nestedLoaded() {
      6  parent.postMessage({ type: 'NESTED_LOADED' }, '*');
      7 }
      8 </script>
      9 <iframe src="empty.html?nested=true" id="nested" onload="nestedLoaded()"></iframe>
     10 <script>
     11 // Helper routine to make it slightly easier for our parent to find
     12 // the nested frame.
     13 function nested() {
     14  return document.getElementById('nested').contentWindow;
     15 }
     16 
     17 // NOTE: Make sure not to touch the iframe directly here.  We want to
     18 //       test the case where the initial about:blank document is not
     19 //       directly accessed before load.
     20 </script>
     21 </body>
     22 </html>