OverTheWire: Bandit Level 22
This is going to be a walkthrough of Level 22 of Bandit from OverTheWire Wargames.
We found the password from level 21.
Username: bandit22
Password: Yk7owGAcWjwMVRwrTesJEwB7WVOiILLI
The information tells us that there is cron job running and we should check /etc/cron.d
for the configuration file.
So lets SSH into the box and navigate to /etc/cron.d
.
There is a job for bandit23
and we can cat
it to see what script it runs.
We see a script in /usr/bin
is run. So lets also cat
that file to see the script that is running.
We see a script that declares some variables and copies the next levels password into a tmp file.
So we need to find out what the variable mytarget
comes out as. So to do this, we can just type the command into the terminal to get the md5sum
string.
Notice that for myname
, we type in bandit23 as that is the password we are trying to find. Next we just cat /tmp/8ca319486bfbbc3663ea0fbe81326349
to find the password that was run by the script.
And we get the next levels password.
To continue, please read my Bandit 23 walkthrough. Level 23
Thank you for reading.