Created
December 20, 2017 15:18
-
-
Save dev-zzo/97c416b17b5305af1e4bea86b3da9ffe to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <html> | |
| <body> | |
| <script> | |
| document.cookie = "FANCYPANTS"; | |
| console.log("parent origin: " + self.location.origin); | |
| console.log("cookie: " + document.cookie); | |
| var html = '<bo'+'dy><scr'+'ipt>console.log("iframe origin: " + self.location.origin);console.log("cookie: " + document.cookie);</scr'+'ipt></bo'+'dy>'; | |
| var iframe = document.createElement('iframe'); | |
| iframe.src = 'data:text/html;charset=utf-8,' + encodeURI(html); | |
| document.body.appendChild(iframe); | |
| </script> | |
| </body> | |
| </html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment