Skip to content
Path traversal Write-up Intermediate

The Complete Compromise of a Password Manager Site

A path traversal vulnerability in a minify function allowed reading arbitrary files, which exposed database and email credentials. Attackers could then access the entire user database, take over employee mailboxes, and gain admin panel access.

jhaddix.com

Published on jhaddix.com

Here's one of my stories about a security assessment I did on a password manager company. One of my teams and I could have accessed hundreds of thousands of passwords from users on the internet.

The author, on jhaddix.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the minify function's path sanitisation was flawed: it removed periods but allowed underscores to be interpreted as path separators, enabling directory traversal.

Impact

The attackers could access the complete user database, take over all employee mailboxes, and control the admin panel, potentially exposing hundreds of thousands of passwords.

What the attacker needed

None

How it was found

  1. Discovered the /123/minify/minfycss/ path during content discovery and spidering.
  2. Fuzzed the path with traversal sequences and observed PHP errors related to incorrect pathing.
  3. Learned from CodeIgniter documentation that underscores could replace slashes, and crafted a traversal using underscores to read /etc/passwd.
  4. Used the file read to download CodeIgniter configuration files, which contained database and Gmail credentials.
  5. Logged into phpMyAdmin with the database credentials and added themselves to the admin panel whitelist.
  6. Uploaded a PHP shell disguised with a GIF header to bypass image upload checks.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

A path traversal bug lets an attacker use '..' to climb out of the intended folder and read files elsewhere on the server. Here, the minify feature stripped periods but could be tricked with underscores, so the attacker read configuration files containing passwords. Those passwords then opened the database and email accounts.

What is Path traversal?

Input that builds a file path escapes the intended folder, reading or writing files the application should never touch.

Similar reports

View all

Same bug class and techniques, clearest first.

Path traversal and file inclusion

The lesson behind this report.

Input that builds a file path escapes the intended folder, reading or writing files the application should never touch.