Friday, July 10, 2015

OverTheWire - Leviathan - Level 0

If you have gone through the Bandit levels you will notice there do not appear to be any level goals for the Leviathan levels which will make understanding what we need to do a little bit harder to accomplish. This may be why the Leviathan levels are given a difficulty of 1 - or Bandit was just that easy. Who knows.

First log into Leviathan0 and check to see if we have anything in our home directory that will allow us to get into Leviathan1 easily.
ls ~
This command returns nothing. Odd.. Let us check for hidden folders then.
ls -a
There we go! Now we will see a .backup folder - let us check out what's in there.
ls -a ./.backup
Interesting, a bookmarks.html. Let us check the contents maybe?
cat ./.backup/bookmarks.html
Oh my goodness, that is a file of word-vomit. Fortunately for us, we have the grep tool. Since we are looking for a password we will use grep to search for password.
cat ./.backup/bookmarks.html | grep "password"
Only a few items will be returned. You can probably find the password from here. Since I like challenging myself to try to solve the level in a single line the following command sequence gets me the closest - just note that the last '"' must come off before using the password to log into leviathan1.
cat ./.backup/bookmarks.html | grep "password" | gawk '{print $14}'

No comments:

Post a Comment