Title: Access Log
Category: Sensitive Data Exposure
Difficulty: ⭐⭐⭐⭐ (4/6)
This challenge tasked us with gaining access to any of the server's access log files.
- Browser: Used to navigate the Juice-Shop application and attempt various URLs to find the logs.
- Text Editor: For analyzing URLs and formulating strategies to access hidden files.
-
Initial Attempts:
- Began by trying to locate the log files through commonly known SIEM endpoints and directory traversal methods. Initial efforts included trying to access well-known SIEM tool endpoints (such as Splunk's standard paths) directly through the browser but were met with HTTP errors or blank pages.
- Exploration Through Application:
- Investigated various parts of the application to understand its structure better and hypothesized that sensitive data like access logs might be exposed through less secure or overlooked parts of the application.
- Utilizing Elevated Access:
- After gaining access to a support user account through a previous 6-stars level challenge (Login Support), re-evaluated available options for access paths that might be relevant to a support user.
- Discovery of Log Access:
- Accessed the URL
127.0.0.1:3000/support/logs
directly from the browser, which was a new path deduced based on the role and possible needs of a support user within the application. This method of guessing the url was highly encourage by hints of the challenge.
- Accessed the URL
-
Downloading Logs:
- Found and downloaded the logs listed on the
/support/logs
page. This confirmed that the correct log files were exposed and accessible, validating the challenge.
- Found and downloaded the logs listed on the
The specific URL to the logs was not directly linked or indicated from the main user interface and required speculative access based on our new role capabilities.
- Restrict Sensitive Directory Access: Ensure that directories containing sensitive information like logs are not accessible via simple URL changes or without appropriate authentication and authorization checks.
- Role-Based Access Controls: Implement robust access control mechanisms that restrict access to sensitive functionalities based on user roles.