summaryrefslogtreecommitdiffstats
path: root/dom/security/test/csp/file_upgrade_insecure_loopback.html
blob: b824604b6e4f4d76eb0fb20f73cf6c2c610ecec4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<!DOCTYPE HTML>
<html>
<head>
  <meta charset="utf-8">
  <title>Bug 1447784 - Implement CSP upgrade-insecure-requests directive</title>
</head>
<body>

<script type="text/javascript">
  // === TEST 1
  var url1 = "http://127.0.0.1:8888/tests/dom/security/test/csp/file_upgrade_insecure_loopback_server.sjs?test1";
  var xhr1 = new XMLHttpRequest();
  xhr1.open("GET", url1, true);
  xhr1.onload = function() {
  	window.parent.postMessage(xhr1.response, "*");
  };
  xhr1.onerror = function() {
  	window.parent.postMessage("test1-failed", "*");
  };
  xhr1.send();

</script>

</body>
</html>