blob: aab27aef1c900ad968a6f01ee5e05fec26320000 [file] [log] [blame]
<!DOCTYPE html>
<html>
<head>
<script src="/js-test-resources/js-test.js"></script>
<script>
var object;
function objectLoad() {
object = document.getElementById('object');
object.onbeforeload = () => {
object.onbeforeload = null;
let base = document.head.appendChild(document.createElement('base'));
base.href = 'javascript:///%0aalert("FAIL");//';
finishJSTest();
};
object.data = 'xxxxx';
};
</script>
</head>
<body>
<script>
description("Check that forcing a navigation during an object element load is well-behaved.")
window.jsTestIsAsync = true;
</script>
<object id='object' type='text/html' data='http://127.0.0.1:8000/plugins/resources/cross-frame-object-access.html' onload='objectLoad()'>
</object>
</body>
</html>