
OverTheWire Bandit Level 0 → 1 Walkthrough
Logging into SSH and reading a file with cat
Series · 20 parts
Bandit is the beginner wargame from OverTheWire. Each level hides the password for the next one somewhere on a Linux machine, and these are my write-ups for levels 0 to 19.

Logging into SSH and reading a file with cat

Reading a file named with a dash using a path prefix

Reading a filename with spaces using quotes or backslash

Finding and reading a hidden file with ls -a

Using the file command to find the only human-readable file

Using find with a size filter to locate the password among many decoy files

Searching the whole server by owner, group, and size with find

Extracting a password next to the word 'millionth' with grep

Finding the only unique line in a file using sort and uniq -u

Using strings to extract human-readable text from a binary file

Decoding base64-encoded data with the base64 command

Decoding a ROT13 cipher using the tr command

Decompressing a repeatedly-compressed hexdump with xxd, gzip, bzip2, and tar

Using an SSH private key to log in without a password

Submitting a password to a localhost port using netcat

Submitting a password over SSL using openssl s_client

Port scanning with nmap to find the SSL listener and get an SSH key

Using diff to find the one changed line between two password files

Bypassing .bashrc logout by running a command directly over SSH

Using a setuid binary to read a file owned by another user