Skip to content
Info disclosure Disclosed report Beginner

Node modules path disclosure due to lack of error handling

Changing a POST request to a GET request on an integration server returned a full error stack trace instead of an HTTP 404. This revealed the full path of the Node.js modules directory on the server.

apapedulimu Follow

Originally disclosed on HackerOne

  • Triaged in 2 days
  • Fixed in 2 days
  • Paid in 2 days
  • Disclosed after 2 months

Summary by the program

On May 2nd, 2017 @apapedulimu reported an issue where changing a POST request to a GET request on one of our integration servers returned a full error stack trace rather than an HTTP 404 error. The full error stack trace revealed the full path of the Node.js modules directory on the integration server. We deployed a fix to this issue whereby an HTTP 404 was returned instead.

The original report as published on HackerOne, by apapedulimu. 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 lacked proper error handling for unexpected HTTP methods, causing a stack trace to be returned.

Impact

The error stack trace revealed the full path of the Node.js modules directory on the integration server.

What the attacker needed

Access to the integration server

The fix

The issue was fixed by returning an HTTP 404 instead of the error stack trace.

How it was found

  1. Send a POST request to a specific endpoint on the integration server.
  2. Change the request method to GET and send it again.
  3. Observe that the server returns a full error stack trace instead of an HTTP 404.
  4. Read the stack trace to find the full path of the Node.js modules directory.

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 the server got an unexpected request, it replied with a detailed error message that included the folder path where the server's code lives, instead of a simple 'not found' message.

What is Info disclosure?

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

More by apapedulimu

View all

9 more disclosed reports, best first.

More from Mapbox

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.