Bandit 4 → 5
Goal: find the only human-readable file among ten in the inhere directory.
Approach
Section titled “Approach”bandit4@bandit:~/inhere$ file ./*./-file00: data./-file01: data./-file02: data./-file03: data./-file04: data./-file05: data./-file06: data./-file07: ASCII text./-file08: data./-file09: databandit4@bandit:~/inhere$ cat ./-file07The password you are looking for is: <password>Password
4oQYVPkxZOOEOO5pTW81FB8j8lxXGUQwWhy it works
Section titled “Why it works”file classifies each input by inspecting its leading magic bytes and content rather than its name, so the one ASCII text file stands out from nine binaries without opening each by hand. The ./ prefix again keeps the dash-led names from reading as options.