Bandit Level 19 → Level 20
Level Goal
To gain access to the next level, you should use the setuid binary in the homedirectory. Execute it without arguments to find out how to use it. The password for this level can be found in the usual place (/etc/bandit_pass), after you have used the setuid binary.
Level Answer
1.
$ ./bandit20-do
Run a command as another user.
Example: ./bandit20-do id
2. ./bandit20-do [id]
$ ./bandit20-do cat /etc/bandit_pass/bandit20
GbKksEFF4yrVs6il55v6gwY5aVje5f0j
3. ssh [-p port] [user@]hostname
- [-p port] Port to connect to on the remote host.
$ ssh -p 2220 [email protected]
Level Password
GbKksEFF4yrVs6il55v6gwY5aVje5f0j