tenfourfox/dom/security/test/csp/file_upgrade_insecure_reporting.html
Cameron Kaiser c9b2922b70 hello FPR
2017-04-19 00:56:45 -07:00

24 lines
654 B
HTML

<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8">
<title>Bug 1139297 - Implement CSP upgrade-insecure-requests directive</title>
</head>
<body>
<!-- upgrade img from http:// to https:// -->
<img id="testimage" src="http://example.com/tests/dom/security/test/csp/file_upgrade_insecure_reporting_server.sjs?img"></img>
<script type="application/javascript">
var myImg = document.getElementById("testimage");
myImg.onload = function(e) {
window.parent.postMessage({result: "img-ok"}, "*");
};
myImg.onerror = function(e) {
window.parent.postMessage({result: "img-error"}, "*");
};
</script>
</body>
</html>