DEV Community

Cover image for OverTheWire - Bandit 6 to 11
Akshay Rao
Akshay Rao

Posted on

1 1

OverTheWire - Bandit 6 to 11

Note:-Don't forget to logout before moving to next level
Level5 -> Level6
Question:-The password for the next level is stored in a file somewhere under the inhere directory and has all of the following properties:

  • human-readable
  • 1033 bytes in size
  • not executable Answers:- use find command to when the properties of files are known
cd inhere
ls
find -size 1033c ! -executable
ssh bandit6@bandit.labs.overthewire.org -p 2220
Enter fullscreen mode Exit fullscreen mode

Image description
Level6 -> Level7
Question:-The password for the next level is stored somewhere on the server and has all of the following properties:

  • owned by user bandit7
  • owned by group bandit6
  • 33 bytes in size Answers:-
cd /
find / -user bandit7 -group bandit6 -size 33c
Enter fullscreen mode Exit fullscreen mode

Image description
have to put rest of the thing is error so use 2>for stderr and send to dev/null

find / -user bandit7 -group bandit6 -size 33c 2>/dev/null
cat /var/lib/dpkg/info/bandit7.password
ssh bandit7@bandit.labs.overthewire.org -p 2220
Enter fullscreen mode Exit fullscreen mode

Level7 -> Level8
Question:-The password for the next level is stored in the file data.txt next to the word millionth.
Answer:- use Grep for filtering the lines according to the word in the quotes, -n will display the line and line number

ls
grep -n “millionth” data.txt 
ssh bandit8@bandit.labs.overthewire.org -p 2220
Enter fullscreen mode Exit fullscreen mode

Image description
Level8 -> Level9
Question:-The password for the next level is stored in the file data.txt and is the only line of text that occurs only once.
Answer:- use piping for combining commands

cat data.txt | sort | uniq -u
ssh bandit9@bandit.labs.overthewire.org -p 2220
Enter fullscreen mode Exit fullscreen mode

Level9 -> Level10
Question:-The password for the next level is stored in the file data.txt in one of the few human-readable strings, preceded by several ‘=’ characters.
Answer:- "-E"indicates extended Grep that the pattern can symbols can repeat.

Strings data.txt | grep -E “=+”
ssh bandit10@bandit.labs.overthewire.org -p 2220
Enter fullscreen mode Exit fullscreen mode

Level10 -> Level11
Question:-The password for the next level is stored in the file data.txt, which contains base64 encoded data.
Answer:- "-d" to decode the base64

Base64 -d data.txt
ssh bandit11@bandit.labs.overthewire.org -p 2220
Enter fullscreen mode Exit fullscreen mode

Speedy emails, satisfied customers

Postmark Image

Are delayed transactional emails costing you user satisfaction? Postmark delivers your emails almost instantly, keeping your customers happy and connected.

Sign up

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay