Previous Level Guide: Bandit Level 12 → 13
Access
SSH: ssh bandit13@bandit.labs.overthewire.org -p 2220
Password: ttw6eXkWHrFGZDgATKirZ4a8a8NGG0Bq
Info
Description: The password for the next level is stored in /etc/bandit_pass/bandit14 and can only be read by user bandit14. For this level, you don’t get the next password, but you get a private SSH key that can be used to log into the next level. Note: localhost is a hostname that refers to the machine you are working on Commands: ssh, telnet, nc, openssl, s_client, nmap
Theory
To get the password, the instructions say that we have to use a private key that is inside a file and can only be read by the next level's user, so that means we will need to use ssh inside the bandit13 terminal, this being the case because it's the only way to access using a private key, it also says in the instructions private SSH key, which already gives it away. Basically, after reading through the manual, we will put an -i option to specify the private key file as our password for the next level, aka bandit14. So after putting this into our usual ssh command, it looks just like this:
ssh -i privkey_file.txt bandit14@bandit.labs.overthewire.org -p 2220
Solution
So now let's enter the level and see what happens:
~$ ls sshkey.private
I'd guess the only file by the name of sshkey.private should be the file we'll use for the command, so just replace it for the filename up there and enter this command:
~$ ssh -i sshkey.private bandit14@bandit.labs.overthewire.org -p 2220
IMPORTANT: Now that you're inside bandit14, you're gonna want to keep this session open because the only way to enter the next level is with the private key in this level.
https://overthewire.org/wargames/bandit/bandit14.htmlNext Level Guide: Bandit Level 14 → Level 15