2021-06-28 15:55:30 +02:00
|
|
|
<!doctype html>
|
|
|
|
<html lang="en">
|
|
|
|
<head>
|
|
|
|
<script>
|
2021-06-28 16:13:38 +02:00
|
|
|
var script = document.createElement('script');
|
|
|
|
// Don't do this at home kids! The "document.referrer" part is actually inserting a XSS security.
|
|
|
|
// We are OK in this precise case because the HTML page is hosted on the "maps" domain that contains only static files.
|
|
|
|
script.setAttribute('src', document.referrer + 'iframe_api.js');
|
|
|
|
document.head.appendChild(script);
|
2021-06-28 15:55:30 +02:00
|
|
|
</script>
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<p>Website opened by script.</p>
|
|
|
|
<script>
|
|
|
|
WA.sendChatMessage('The iframe opened by a script works !', 'Mr Robot');
|
|
|
|
</script>
|
|
|
|
</body>
|
|
|
|
</html>
|