Bandit1
bandit level 1
ssh server: bandit.labs.overthewire.org port 2220
username: bandit1
password: boJ9jbbUNNfktd78OOpsqOltutMc3MY1
connect to the ssh server
The bandit1 home directory contains nothing else a file with name dash "-", Linux uses -'s to add command arguments which means that the file can not be directly be read by the cat command
the work around is to not add the - direct next to the cat command, this could be dome in several ways
$ cat ./-
this means print out the contents of the file named - which in the root of current directory
OR
$ cat /home/bandit1/-
this means print out the contents of the file named - which in the bath /home/bandit1
OR
$ cat < -
direct the contents of the file - to be printed
OR
$ dd if=- 1>/div/stdout
convert and copy the Input File named - to the standard output (the screen)
this prints some unneeded data, that's why we use the next format
$ dd if=- 2>/dev/null
convert and copy the Input File named - to the standard output (the screen), but direct the unneeded data to a null device
all the previse methods will print out the contents of the file "-" which is the password for the next challenge bandit2
lets meet in bandit2
Your comments and feedback
are highly appreciated
Thank You
No comments:
Post a Comment