| my rAnd0m m1ndfl0w |
| #whoami $bl0g /script.s retr0gaming |
Disobey 2023 - CTF - The New and Improved ROT13 ----------------------------------------------- The assignment was:
Instead of systematically choosing the next letter in the alphabet as the substitution, it's better to have a more
complicated pattern of substitution, like jumping ahead by a letter or three, or even completely scrambling the entire
alphabet. The most common of these schemes is called Rot13, moving ("rotating") each letter exactly 13 places forward
along the English alphabet.
However, no matter how complicated the substitution scheme, if you know the language of the plaintext, counting the
number of occurrences of each letter will very quickly reveal the substitution scheme. To fight this, you can
switch the substitution scheme each time you encrypt a letter.
For example, this message was encrypted by a method that is definitely not called Rot13 although it could be:
PQF WIUFH JQTWFDE RG WILSWFHO
This one was quite easy if you're in any way even the slightest bit familiar with good old encryption methods, in this case Vigenere cipher, whichs is what's described in the assignment. For this I decided to use the grandfather of CyberChef, dcode.fr's Vigenere cipher tool. Just input the ciphertext and all I had to do was figure out a plaintext word to guide the decoding. I decided to go with the first three letter word in the cipher PQF which in English most likely would be "THE" and try decrypting: BHBDBD OJE THREA INSTEWD OF THERTEEN BDBDBQ ONE THEEE INSGEAD OF GHIRTERN BDBDAP ONE TIFEE INTHEAD OG HHIRTFSN BDBH ONE PHREA INSPEAD KF THERTEAN BDBDYD ONE TKREE INVTEAD OI THIRTHEN BDMPED ONT HEREE XBPTEAS CC THIGHBEN BQBD OAE THEEE IASTEND OF GHIRGEEN MSOVX DYR BLINT OTHERIH FO INOGERMR OSOPE BYR HEGNT UMFEROA DO ITHEERSK BDYD ONH THRHE INVTEAG OF TKIRTHEN BDZPBD ONG HHREE KBSTEAF CF THITHEEN The first 11 suggestions give quite a good clue about the actual solution, but just to be on the safe side I tried another key based on the previous results: THIRTEEN, which produced: BDBD ONE THREE INSTEAD OF THIRTEEN BDBDBD ONE THREE INSTEAD OF THIRTEEN And there we had the solution, though the naughty designer wasn't really following any formatting "standard" for the flag, but still, the flag was: ONE THREE INSTEAD OF THIRTEEN |