How I hacked medium and they didn’t pay me
A race condition in Medium's clap system allowed an attacker to send multiple concurrent requests to manipulate the clap count of any article or comment, either driving it negative or inflating it. This could damage a writer's reputation and indirectly affect their earnings from the Partner Program.
super_burgundy_weasel_439 Follow
Published on medium.com
TL;DR : I found a bug which allows negativizing or increasing or bricking the claps count of any article/comment, which has indirect effect on writers revenue, and direct effect on their reputation and since they would then miss out on paid users claps (which are worth money) making the effect rather direct.
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 a race condition in the clap handling logic, where concurrent requests are processed without adequate locking, allowing the clap count to be manipulated.
Impact
An attacker could negativize or increase the clap count of any article or comment, potentially affecting writers' reputation and indirectly their earnings, though Medium stated it doesn't affect writers' earnings directly.
What the attacker needed
A Medium account; Burp Suite v2023.9.1 or higher
How it was found
- Click clap on an article
- Intercept the request
- Send it to repeater and drop it from proxy
- Change the claps num to 50
- Duplicate the request 19 times
- Add the requests to a group then choose “send requests in parallel single attack”
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 race condition happens when a website handles multiple requests at the same time without proper checks, so the requests interfere with each other. Here, by sending many clap requests simultaneously, the attacker could make the clap count go negative or increase it beyond the allowed limit. This matters because claps are used to rank articles and pay writers.
What is Race condition?
Parallel requests reach a state the code assumed could not happen: a coupon used twice, a limit overrun, a check skipped.