blob: e6620bd29c7537af74b4b8e55e1c5aafb319ca50 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
<!DOCTYPE HTML>
<html>
<head>
<title>Referer with location.replace and nested frames</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
</head>
<body>
<iframe src="resources/replace-or-assign-call-on-iframe.html?replace" hidden></iframe>
<script>
async_test(function(t) {
function on_message(e) {
const nestedIframeReferrer = e.data;
assert_equals(nestedIframeReferrer, document.querySelector("iframe").contentWindow.location.href);
t.done();
}
window.addEventListener('message', t.step_func(on_message), false);
}, "Browser sends Referer header when location.replace is called in iframe document on another nested iframe element");
</script>
</body>
</html>
|