overthewire-writeups

Bandit17 -> 18: Spot the Difference

Challenge

Level Description

There are two files in the home directory: passwords.old and passwords.new. The password for the next level is in passwords.new and is the only line that has been changed between the two files.

The Process

When I logged in, I saw two large files. Looking through them manually would be a nightmare because they contain many similar-looking strings.

In Linux, there is a perfect tool for this called diff. It compares two files line by line and shows exactly what is different between them.

Here is the command I used:

$ diff passwords.old passwords.new

The output showed a few lines, but specifically, it pointed out the line that was removed from the old file and the new line added to the current file. The line marked with a > (indicating it belongs to the second file, passwords.new) was the password I needed.

Password For the Next Level

[SPOILER]

What I Learned

Helpful Reading Material