Previous Level: Introduction
Login
SSH: ssh krypton1@krypton.labs.overthewire.org -p 2231
Task
The password for level 2 is in the file ‘krypton2’. It is ‘encrypted’ using a simple rotation. It is also in non-standard ciphertext format. When using alpha characters for cipher text it is normal to group the letters into 5 letter clusters, regardless of word boundaries. This helps obfuscate any patterns. This file has kept the plain text word boundaries and carried them to the cipher text. Enjoy!
A little bit of Theory
ROT13
is an easy substitution cryptosystem based on the Caesar cipher but with 13 as the key. This key has the advantage that the encryption function is the same as the decryption function for the Latin alphabet with 26 letters. This also exists for the 10 digits and is called ROT5.
The Caesar cipher
is a shift cipher, meaning the letters are shifted by a certain number (the key). For example, with k=1, you encrypt A as B, B as C and so on until Z will be encrypted as A.
The bash command alias
allows you to create shorter names for common commands. The structure is: alias <alias_name>="<lang_common_command>"
tr
is the translate command. It allows you to replace or delete characters. It is used in UNIX pipes (find out more see [Bandit Level 6]https://mayadevbe.me/posts/overthewire/bandit/level6/). The structure for replacing characters is the following: tr '<initial_chars>' 'replacement_chars'
. For example echo 'A' | tr 'A' 'a'
would return a
.
Solution
Based on the description in the previous level, it is said that the files for the levels are in the ‘/krypton/’ folder.
|
|
In the ‘krypton1’ directory, we find two files. The ‘README’ file explains the game and gives us an additional hint on how to solve this level.
|
|
The text states that the file is encrypted with ‘ROT13’. There are a lot of websites that you can use to decrypt ROT13, but I’m gonna use the command line. ROT13 is so common that you might want to create an alias.
Creating the aliases (ROT5 is not needed, but I added it anyway):
|
|
You can use this to decrypt the cipher text.
|
|
https://overthewire.org/wargames/krypton/krypton1.html
Next Level: Level 2