Skip to content
Info disclosure Write-up Beginner

My First Bug: Gitingore exposure combined with 403 bypass

A .gitignore file was exposed on a web server behind a directory that returned 403 Forbidden, and the author bypassed the 403 using fuzzing to access the file. The file could reveal sensitive configuration information, though the report was rated informational with no payment.

nnface Follow

Published on medium.com

I wanna describe how i was able to make some common or little complicated bug, but unfortunately i was not paid, but im here to share it with you all, Lets move

NnFace, on medium.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 web server's access control for the /media directory was misconfigured, allowing direct access to files like .gitignore despite the directory listing being forbidden.

Impact

The exposed .gitignore file could reveal sensitive file paths or configuration details, but the report was rated informational with no payment, suggesting limited impact.

What the attacker needed

None

How it was found

  1. Enumerate subdomains and crawl to find directories.
  2. Identify the /media directory returning 403 Forbidden.
  3. Attempt classic 403 bypass techniques without success.
  4. Use a fuzzer with combined wordlists to discover accessible files.
  5. Find that /.gitignore returns 200 OK and downloads automatically.

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 .gitignore file is a text file that tells the version control system Git which files to ignore. If it is publicly accessible, it can reveal the names of sensitive files or directories that the developer intended to keep private. The author found that a directory normally blocked with a '403 Forbidden' error could be accessed by guessing the right file name, leading to the download of this file.

What is Info disclosure?

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

More by nnface

View all

4 more disclosed reports, best first.

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.