The IDOR That Played Hide-and-Seek in the URL Path
The upload endpoint took the project identifier from the URL path but only checked that the caller was a logged-in user, not that they belonged to that project. An attacker could therefore upload files into another user's project by swapping the project ID.
medium.com
Published on medium.com
Finding vulnerabilities is often like detective work. You follow clues, look for inconsistencies, and sometimes, the culprit is hiding right where you least expect it.
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
Impact
An attacker could inject or overwrite files in another user's project, fill their storage quota, and potentially spread malware if uploaded files are previewed or executed.
What the attacker needed
A free account; knowledge of the victim's project ID
The fix
The server should check, for every request, that the logged-in user is a member of the project named in the path before accepting the upload.
How it was found
- Log in as one user and create a project, then upload a file to it and intercept the request.
- Note that the project ID sits in the URL path of the upload request.
- Replace that project ID with another user's project ID while keeping your own session token.
- Send the request and observe that the server accepts the upload.
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 project ID is a label the site uses to pick which project to act on. Here the server checked that you were logged in but never checked that the project in the address belonged to you. So anyone with an account could drop files into a stranger's project just by changing that label.
What is IDOR?
One user can read or change another user's data, usually by changing an identifier the server trusts without checking who is asking. One of the most paid bug classes on web programs.