Alternative link
The article describes several path traversal and local file inclusion vulnerabilities found in different applications, allowing attackers to read arbitrary files such as source code, system files, and licence keys. In one case, an unauthenticated endpoint allowed reading the Windows hosts file and enumerating the webroot to find a licence file.
synack.com
Published on synack.com
Taxonomy Bug Bounty
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 applications failed to sanitise user-supplied file names before using them to read files from the filesystem.
Impact
An unauthenticated attacker could read arbitrary files on the server, including system files and licence keys, and in other cases authenticated users could disclose source code or list directories.
What the attacker needed
None for the unauthenticated case; authentication for some other cases
How it was found
- Visit the webroot and get redirected to the login page.
- Observe a request to /web/product_logo with a logo parameter containing a file name.
- Change the logo parameter to a path traversal sequence pointing to the Windows hosts file.
- Increase the number of '../' sequences until the hosts file is returned.
- Use the path traversal to fuzz the webroot and discover a LICENSE file.
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.
Path traversal is a flaw where a program uses user input as part of a file path without proper checks, so an attacker can use sequences like '../' to escape the intended folder and read other files on the server. Local file inclusion is similar but often involves including files in the application's output. Here, the author found several places where changing a file name parameter let them download sensitive files.
What is Path traversal?
Input that builds a file path escapes the intended folder, reading or writing files the application should never touch.