"Backslash+space". Like, If Your Folder Name Is "Am A Programmer" Then The CD Command Will Be, "CD
"Backslash+space". Like, If Your Folder Name Is "Am A Programmer" Then The CD Command Will Be, "CD
LEVEL 0
ssh -p 2220 [email protected]
pass: bandit0
ls
readme
cat readme
pass for level 1
LEVEL 1
ssh -p 2220 [email protected]
pass:enter the pass obtained in level 0
LEVEL 2
ls
-
bandit1@bandit:~$ cat /home/bandit1/- //When cat sees the string - as a filename, it treats it as a
synonym for stdin. To get around this, you need to alter the string that cat sees in such a way that it
still refers to a file called -. The usual way of doing this is to prefix the filename with a path - ./-, or
/home/Tim/-.
u get pass
exit
LEVEL 3
ssh -p 2220 [email protected]
enter pass
cat spaces\ in\ this\ filename //cd Linux\ Drive – open Linux Drive named folder in directory. Here you
can see I use backslash because the folder name has spaces so for each space you use
“backslash+space”. Like, if your folder name is “am a programmer” then the cd command will be, “cd
am\ a\ programmer”.
u get pass
exit
LEVEL 4
ssh -p 2220 [email protected]
input pass
bandit3@bandit:~$ ls
inhere
bandit3@bandit:~$ cat inhere
cat: inhere: Is a directory
bandit3@bandit:~$ find inhere
inhere
inhere/.hidden
bandit3@bandit:~$ cat inhere
cat: inhere: Is a directory
bandit4@bandit:~/inhere$ ls
-file00 -file01 -file02 -file03 -file04 -file05 -file06 -file07 -file08 -file09
bandit4@bandit:~/inhere$ cat ./-file07
koReBOKuIDDepwhWk7jZC0RTdopnAYKh
bandit4@bandit:~/inhere$ cat ./-file03
��.A��u��#��#�w$N?c�-��Db3#��=�#�bandit4@bandit:~/inhere$ exit
logout
Connection to bandit.labs.overthewire.org closed.
jaihonikhil@jaihonikhil-HP-Pavilion-Laptop-15-cs1xxx:~$
LEVEL 5
koReBOKuIDDepwhWk7jZC0RTdopnAYKh
bandit5@bandit:~/inhere$ find . -type f -readable ! -executable -size 1033c
./maybehere07/.file2
bandit5@bandit:~/inhere$ cat ./maybehere07/.file2 /dev is the location of special
or device files. It is a very interesting directory that highlights one important aspect of the Linux
filesystem - everything is a file or a directory.
DXjZPULLxYr17uwoI01bNLQbtFemEgo7
LEVEL 6
//explanation to this is
/dev/null is the null device it takes any input you want and throws
it away. It can be used to suppress any output.
Further, 2> means that you are redirecting (i.e. >) the stderr (i.e. 2) into the black hole (i.e.
/dev/null)
LEVEL 7
bandit7@bandit:~$ ls
data.txt
bandit7@bandit:~$ cat data.txt|grep "millionth" // grep for finding
millionth cvX2JJa4CFALtqS87jk27qwqGhBM9plV
take this password
LEVEL 8
bandit8@bandit:~$ ls
data.txt
bandit8@bandit:~$ cat data.txt | sort | uniq -u // or use sort data.txt | uniq -u
UsvVyFSfZZWbi6wgC7dAFyFuR6jQQUhR //The | is a pipe that redirects the output from one
command into another.
The uniq command reports or omits repeated lines and by passing it the -u argument we tell it to
report only unique lines.
LEVEL 9
strings data.txt | grep "="
use this
truKLdjsbJ5g7yyJ2X2R0o3a5HQJFuLk
LEVEL 10
bandit10@melinda:~$ cat data.txt | base64 --decode
The password is IFukwKGsFW8MOq3IRFqrxE1hxTNEbUPR