blob: 62c1df153938f941f761aa76de893a4bc88166e7 [file] [log] [blame]
<!DOCTYPE html>
<html>
<body>
<iframe></iframe>
<p>
This tests that blob URLs created in a secure context are treated as secure
origins. This test passes if the iframe renders PASS correctly, and no
console warning appears.
</p>
<script>
if (location.protocol != 'https:')
location = 'https://127.0.0.1:8443/security/mixedContent/blob-url-in-iframe.html';
if (window.testRunner) {
testRunner.dumpAsText();
testRunner.dumpChildFramesAsText();
testRunner.waitUntilDone();
}
var iframe = document.querySelector('iframe');
iframe.onload = function () {
if (window.testRunner)
testRunner.notifyDone();
};
var b = new Blob(['<h1>PASS (1/1)</h1>'], { type: 'text/html' });
iframe.src = URL.createObjectURL(b);
</script>
</body>
</html>