Bandit Level 18
-
When you try to SSH in, you get kicked out immediately with the message
Byebye!. Someone has modified.bashrcto runexitas soon as an interactive shell starts. -
The trick is to pass a command directly to SSH so it executes before the shell even loads
.bashrcinteractively.ssh bandit18@localhost -p 2220 cat readmeappendscat readmeat the end of the ssh command, which runs the command on the remote machine without spawning an interactive shell.- This bypasses
.bashrcentirely and just dumps the file contents.


Password
kfBf3eYk5BPBRzwjqutbbfE887SVc5Yd