Directory Indexing on the ████ (https://████/) leads to the backups disclosure and credentials leak
A web server had directory indexing enabled, exposing a debug folder that contained a zipped source code backup and a configuration file with database credentials. An attacker could download the source code and credentials to compromise the resource.
- Triaged in 8 hours
- Fixed in 6 months
- Disclosed after 16 months
##Description
During poking around █████████/24 range - █████ looking for the Cisco devices, I came across █████ which resolved to the https://██████/
While it's a not .mil host, it's likely related to the DoD since it hosted in the DoD-controlled ASN.
I discovered few critical vulnerabilities here, one of them is exposed backup files via directory listing.
##POC https://███/obj/Debug/ █████ The source code can be found here: https://█████████/obj/Debug/Package/GLOSS2.zip It's zipped backup.
The DB credentials exposed here: https://█████/obj/Debug/Package/GLOSS2.SetParameters.xml ███
##Suggested fix Disable directory indexing, restrict access to the sensitive files, and change credentials as defense-in-depth measure.
Impact
Source code & DB credentials leakage. Attacker can use it to compromise the resource.
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 directory indexing was left enabled on a folder holding build/debug artefacts, and sensitive backup and configuration files were stored there without access restrictions.
Impact
Source code and database credentials were leaked, which an attacker could use to compromise the resource.
What the attacker needed
Target host reachable; directory indexing enabled; no authentication on the folder
The fix
Directory indexing should be disabled, access to sensitive files restricted, and the exposed credentials changed as a defence-in-depth measure.
How it was found
- Scan the address range and find the host that resolves to the target site.
- Open the debug folder path on the site to see a directory listing.
- Download the zipped source code backup from that listing.
- Open the settings file in the same folder to read the exposed database credentials.
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.
Some web servers show a list of files when a folder has no index page, which is called directory indexing. Here that listing revealed a backup of the site's source code and a settings file holding database usernames and passwords, so anyone who found the folder could download them.
What is Info disclosure?
Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.