Cryptography can be easy, do you know what ROT13 is? cvpbPGS{arkg_gvzr_V'yy_gel_2_ebhaqf_bs_ebg13_uJdSftmh}
We are told that the flag is encrypted with ROT13, which is a simple substitution cipher that replaces every character with the character that is 13 spaces along the alphabet. For example, the character C
would be replaced by a P
:
You can see that C
is the 3rd index, and P
is in fact the 16th. But what if we want to encrypt the letter Y
, at index 25? Well, what we do here is we loop back to the beginning; if we do this, the character 13 positions after it is in fact L
!
Mathematically, we can see that the index that would be position 26
is actually looping back to position 0
, so we add on the 13
and take the remainder modulo 26. We can do this easily in Python, ignoring non-letter characters: