Critical IDOR on chat message (1000 USD)
An API endpoint that returned chat messages accepted arbitrary numeric message identifiers without checking ownership, so any user could read other users' conversations. The hunter enumerated identifiers and found chat content containing S3 links that exposed other users' personally identifiable information.
Published on bytesnull44.medium.com
When I was hunting on a private program, I noticed an API that was not included in their scope, so I ignored it. However, after hunting for several hours, it kept bothering me.
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 API looked up chat messages by their numeric identifier without verifying that the requesting user belonged to the conversation.
Impact
An attacker could read other users' chat messages and, through links found in them, access files containing other users' personally identifiable information.
What the attacker needed
Access to the API; valid message identifiers to guess
How it was found
- Notice an API endpoint handling chat messages with a numeric message parameter
- Send requests with random numbers for that parameter
- Observe a 200 OK response instead of a 403 Forbidden for each number
- Write a script to pull the data and search it for sensitive information
- Find S3 links in the chats and manually check them, revealing other users' PII
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.
Every chat message has a number that identifies it. The server should check that the person asking for a message is part of that conversation, but it did not. By simply trying different numbers, the hunter could read other people's chats, which included links to files holding personal details.
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.