dom/tests/mochitest/bugs/file_bug593174_2.html

Tue, 06 Jan 2015 21:39:09 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Tue, 06 Jan 2015 21:39:09 +0100
branch
TOR_BUG_9701
changeset 8
97036ab72558
permissions
-rw-r--r--

Conditionally force memory storage according to privacy.thirdparty.isolate;
This solves Tor bug #9701, complying with disk avoidance documented in
https://www.torproject.org/projects/torbrowser/design/#disk-avoidance.

     1 <html>
     2 <body>
     3 Page 2 has an iframe of its own.
     4 <iframe id='inner-iframe' onload='innerIframeLoaded()' src='data:text/html,
     5       <html><body>
     6         <script>function go() { window.location = "file_bug593174_1.html"; }</script>
     7       </body></html>'>
     8 </iframe>
    10 <script>
    11 function innerIframeLoaded() {
    12   if (parent.iframeLoaded) {
    13     parent.iframeLoaded('inner');
    14   }
    15   else if(opener.iframeLoaded) {
    16     opener.iframeLoaded('popup/inner');
    17   }
    18 }
    20 function navigateInnerIframe() {
    21   document.getElementById('inner-iframe').contentWindow.go();
    22 }
    24 function getInnerIframeReferrer() {
    25   return document.getElementById('inner-iframe').contentWindow.document.referrer;
    26 }
    27 </script>
    29 </body>
    30 </html>

mercurial