The password lives inside a hidden file (its name starts with a dot) inside the inhere directory. Plain ls hides dotfiles — ls -a reveals them.
| Platform | OverTheWire Bandit |
| Category | Linux Fundamentals |
| Level | 3 → 4 |
| Difficulty | Beginner |
| Technique | Hidden files (dotfiles) |
Level 3's home directory contains a subdirectory called inhere. Opening it and listing its contents with a plain ls shows... nothing. That's the trick.
"Level Goal: The password for the next level is stored in a hidden file in the inhere directory."
Log in as bandit3 and move into the subdirectory the level points to:
cd inhere
ls
(empty output)
By convention, any file whose name starts with a dot (.) is hidden from a plain ls — the -a flag shows everything, dotfiles included:
ls -a
.
..
.hidden
There it is — a file called .hidden. Read it directly:
cat .hidden
[PASSWORD FOR bandit4]
The password is deliberately hidden — follow the method, you've earned it. 💪
Unix hides nothing from you — it just doesn't show dotfiles by default to keep directory listings clean. ls -a (or ls -la for the long format with permissions) is the reflex to build for any level, or any real system, where something seems to be missing.
ls, nothing more special than thatls -a lists every entry, including . and ..ls -la combines that with the long format (permissions, size, owner)Ten near-identical files, only one holds the password. Using file to spot the real text file among decoys.
Discuss this writeup with the community on the CTFdojo Discord.
Join the Discord →