PicoCTF2018 - Crypto- Crypto Warmup 2
Objective:
Cryptography doesn't have to be complicated, have you ever heard of something called rot13? cvpbPGS{guvf_vf_pelcgb!}
Solution:
let's solve this in bash
I'm just going to use tr translate to a ROT13
1st shot
@pico-2018-shell:~$ echo "cvpbPGS{guvf_vf_pelcgb!}" | tr '[A-Za-z]' '[N-ZA-Mn-za-m]'
OK it doesn't like to translate "!" because its not alpha we are trying. let's try it again without the !
(I'll just add it back in after the translation)
@pico-2018-shell:~$ echo "cvpbPGS{guvf_vf_pelcgb}" | tr '[A-Za-z]' '[N-ZA-Mn-za-m]'
let's not forget to add the ! back in
picoCTF{this_is_crypto!}
** just a bit of explanation on the tr command
what were doing here is remapping the alphabet for translation
The first bit is the definition of the alphabet as we know it A-Za-z this has two parts one upper and one for lower case
since they were nice enough to tell us that this is ROT13 we know that we need to shift the letters of the traditional alphabet 13 characters
so A gets shifted 13 characters to the right so now an A(which is 1) is a N ( which is 14 or 1 + 13)
that is why the second bit of the tr command starts at N so its saying the alphabet we want to use starts at N goes through Z and the wraps back around and does A through M, uppercase and lowercase
Objective:
Cryptography doesn't have to be complicated, have you ever heard of something called rot13? cvpbPGS{guvf_vf_pelcgb!}
Solution:
let's solve this in bash
I'm just going to use tr translate to a ROT13
echo "cvpbPGS{guvf_vf_pelcgb}" | tr '[A-Za-z]' '[N-ZA-Mn-za-m]'
1st shot
@pico-2018-shell:~$ echo "cvpbPGS{guvf_vf_pelcgb!}" | tr '[A-Za-z]' '[N-ZA-Mn-za-m]'
-bash: !}: event not found
OK it doesn't like to translate "!" because its not alpha we are trying. let's try it again without the !
(I'll just add it back in after the translation)
@pico-2018-shell:~$ echo "cvpbPGS{guvf_vf_pelcgb}" | tr '[A-Za-z]' '[N-ZA-Mn-za-m]'
picoCTF{this_is_crypto}
let's not forget to add the ! back in
picoCTF{this_is_crypto!}
** just a bit of explanation on the tr command
what were doing here is remapping the alphabet for translation
The first bit is the definition of the alphabet as we know it A-Za-z this has two parts one upper and one for lower case
since they were nice enough to tell us that this is ROT13 we know that we need to shift the letters of the traditional alphabet 13 characters
so A gets shifted 13 characters to the right so now an A(which is 1) is a N ( which is 14 or 1 + 13)
that is why the second bit of the tr command starts at N so its saying the alphabet we want to use starts at N goes through Z and the wraps back around and does A through M, uppercase and lowercase
Comments
Post a Comment