Previous Level Guide: Bandit Level 13 → 14
Access
SSH: ssh bandit14@bandit.labs.overthewire.org -p 2220
Password: none (ssh key from previous level)
Info
Description: The password for the next level can be retrieved by submitting the password of the current level to port 30000 on localhost. Commands: ssh, telnet, nc, openssl, s_client, nmap
Theory
To get the password, the instructions say that we have to enter to a localhost in port 30000 and just put the password for entering this level, which we don't use because of the ssh key from the last level. Also, according to the last level we can find the password for this in /etc/bandit_pass/bandit14 because it's only readable by bandit14, where we are right now, so we can use cat for that. Then for this we'll use NetCat, or nc for short. NetCat is a coommand used to access ports from a website or localhost, in this case it's used as a minigame kind of thing, because the localhost will give you the next password if you input the correct previous password. NetCat also lets you use some commands like exit, but it mostly depends on who created the port. After looking through the manual, we can get a command like this:
nc localhost 30000
Solution
So now let's enter the level and get the password needed for the NetCat later:
~$ cat /etc/bandit_pass/bandit14 7WTC1qzhcZHrDk0KWJOHmzXRVOlY6lnk
Now we just use NetCat to connect to the port 30000 in localhost and paste the password in the empty field:
~$ nc localhost 30000 7WTC1qzhcZHrDk0KWJOHmzXRVOlY6lnk Correct! LSAAg2asGSvcoXbFoYEPdlyxdwYqWNei
And that's it, it worked! Now we should be good to go to the next level by exiting from all the things we've entered by using the exit command, such as, localhost, bandit14, bandit13, and optional if you want to exit the terminal, making it look like this:
... Correct! LSAAg2asGSvcoXbFoYEPdlyxdwYqWNei exit ~$ exit logout Connection to bandit.labs.overthewire.org closed. ~$ exit logout Connection to bandit.labs.overthewire.org closed. C:\Users\shukularuni>exit
Pretty funny how you can exit four times in a row.
https://overthewire.org/wargames/bandit/bandit15.htmlNext Level Guide: Bandit Level 15 → Level 16