blob: 03914ce3e57b829a3cc77d1d855fef87cd9e17e7 [file] [log] [blame]
<html>
<head>
<script src="../resources/cross-frame-access.js"></script>
<script>
var openedWindow;
window.onload = function()
{
if (window.testRunner) {
testRunner.dumpAsText();
testRunner.waitUntilDone();
testRunner.setCanOpenWindows();
}
window.addEventListener('message', function ()
{
runTest();
closeWindowAndNotifyDone(openedWindow);
});
openedWindow = window.open("http://localhost:8000/security/dataURL/resources/foreign-domain-data-url-accessee-opened-frame.html");
}
runTest = function()
{
try {
openedWindow[0].document.getElementById('accessMe').innerHTML = "FAIL: Cross frame access to a data: URL embed in a frame window.open'ed on foreign domain allowed.";
log("FAIL: Cross frame access to a data: URL embed in a frame window.open'ed on foreign domain allowed.");
return;
} catch (e) {
}
log("PASS: Cross frame access to a data: URL embed in a frame window.open'ed on foreign domain denied!");
}
</script>
</head>
<body>
<pre id="console"></pre>
</body>
</html>