What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more

From Bandit’s home directory, run cat ./-. The ./ makes the single-dash filename a pathname, so GNU cat opens the file instead of treating - as standard input.

What Bandit Level 1 asks you to do

The OverTheWire Bandit Level 1 → Level 2 goal says the next password is stored in a file named exactly - in the home directory. The page suggests ls, cd, cat, file, du, and find as useful commands.

Bandit is an introductory wargame: each level provides information needed to proceed. Its official overview lists the SSH host as bandit.labs.overthewire.org and the port as 2220. Check OverTheWire’s current pages for access details and credentials, since passwords and service information can change.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Read the file and use its contents

  1. Connect to the appropriate Bandit account using OverTheWire’s current access details and the credentials for the level.
  2. Make sure you are in the home directory; that is where the level says the file is located.
  3. Run cat ./-. The password appears in the terminal.
  4. Use that password to continue to the next level. Avoid relying on a password copied from an old writeup; OverTheWire notes that passwords occasionally change.

Why cat ./- works

GNU cat gives a bare - a special meaning: it reads from standard input rather than opening a file with that name. So cat - does not read the local dash-named file. The GNU Coreutils 9.11 documentation for cat describes this behavior.

In ./-, the prefix ./ identifies a relative pathname in the current directory. It is not an escaping or quoting trick; it makes the argument a path to the file, rather than the special bare-dash operand. GNU Coreutils guidance also uses ./- to refer to a dash-named file.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Why not use --?

Many command-line programs accept -- to mark the end of options, so later arguments that begin with a dash are treated as operands. But cat -- - still passes a bare single dash as the file operand, which GNU cat treats as standard input. For this exact filename, use cat ./-.

Rank #4
LarryBoy Meets the Bubblegum Bandit: Level 1 (I Can Read! / Big Idea Books / VeggieTales)
  • New
  • Mint Condition
  • Dispatch same day for order received before 12 noon
  • Guaranteed packaging
  • No quibbles returns

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.