Summary
Lab Objective The goal of this lab is to locate leaked backup files and extract a hard-coded database password from the disclosed source code. Step-by-Step Solution
- Check robots.txt for hidden paths robots.txt is designed to tell search engine crawlers which paths not to index : /robots.txt revealed a disallowed /backup directory.
- Enumerate the backup directory Browsing directly to /backup surfaced a file named: ProductTemplate.java.bakGet Zeyad Naguib’s stories in your inbox Join Medium for free to get updates from this writer.
- Retrieve and read the leaked source file Navigating to: /backup/ProductTemplate.java.bak
- Extract the hard-coded credential Reading through the disclosed source, the database connection logic contained a hard-coded password used to authenticate against a Postgres database.
- Submit the solution I copied the password value, returned to the lab, clicked Submit solution, and entered it. The lab was marked as solved.