Skip to content
Info disclosure Disclosed report Beginner

Information Disclosure (Directory Structure)

The application exposed full server file paths in PHP error messages when a malformed PHPSESSID cookie was sent. An attacker could learn the internal directory structure and server hostname.

rajuraju14 Follow

Originally disclosed on HackerOne

  • Triaged in 6 hours
  • Fixed in 21 hours
  • Disclosed after 22 hours

The /var/www/ directory structure is exposed if you add "]]>>" to the PHPSESSID in the cookie.

Request: GET / HTTP/1.1 Host: www.localize.io Accept: / Accept-Language: en User-Agent: Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Win64; x64; Trident/5.0) Connection: close Referer: http://www.localize.io/ Cookie: PHPSESSID=bomb3ogic5qur05apsq25nq821]]>>

Response: HTTP/1.1 200 OK Date: Thu, 17 Apr 2014 21:15:53 GMT Server: Apache Pragma: no-cache Expires: Mon, 24 Mar 2008 00:00:00 GMT Cache-Control: no-cache X-Powered-By: PleskLin Vary: Accept-Encoding Content-Type: text/html; charset=utf-8 Connection: close Set-Cookie: PHPSESSID=mg5to8huhbv7bpk3q0003d5kg3; path=/; HttpOnly Content-Length: 5819

Notice: Undefined index: HTTP_ACCEPT_ENCODING in /var/www/vhosts/lvps178-77-99-228.dedicated.hosteurope.de/httpdocs_localize/classes/UI.php on line 147

Notice: Undefined index: HTTP_ACCEPT_ENCODING in /var/www/vhosts/lvps178-77-99-228.dedicated.hosteurope.de/httpdocs_localize/classes/UI.php on line 147

The original report as published on HackerOne, by rajuraju14. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

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

How it worked

Root cause

Likely, the application had PHP error reporting enabled in production, causing notices with full file paths to be displayed to users.

Impact

An attacker could learn the server's directory structure and hostname, which may aid in further attacks.

What the attacker needed

Ability to send HTTP requests with custom cookies

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 report has not been written yet. The Original tab links to the source.

When a website runs into an error, it sometimes shows a detailed message that includes the location of files on the server. Here, by sending a broken session cookie, the attacker made the site reveal its internal folder paths. This helps an attacker plan further attacks by knowing where things are stored.

What is Info disclosure?

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.

More by rajuraju14

View all

2 more disclosed reports, best first.

More from Localize

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Information disclosure

The lesson behind this report.

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.