blob: 4ab95ece3f87d84c7102eae379b92efecd5998a0 [file] [log] [blame]
<!DOCTYPE html>
<html>
<head>
<script src="../../../resources/js-test-pre.js"></script>
<script src="../../media-resources/media-file.js"></script>
<script src="resources/canvas-video-crossorigin.js"></script>
</head>
<body>
<pre id="console"></pre>
<script>
description("Ensure that data cannot be retrieved from a canvas tainted by a video resource obtained via redirection when CORS is not enabled.");
function test()
{
testDataRetrievalForbidden("redirected video resource");
finishJSTest();
}
var video = document.createElement("video");
video.addEventListener("loadeddata", test);
video.src = `/resources/redirect.php?url=http://localhost:8000/${findMediaFile("video", "resources/test")}`;
window.jsTestIsAsync = true;
</script>
<script src="../../../resources/js-test-post.js"></script>
</body>
</html>