Skip to content
Race condition Write-up Beginner

Race Condition!!! On Docker Hub (:

Docker Hub's star/like feature did not properly limit how many times a single account could like the same content. By sending many identical like requests at the same moment, an attacker could register multiple likes from one account, and most of them could not be removed afterwards.

medium.com

Published on medium.com

Here I go with a new finding which is a bit interesting because it is a race condition on the top of that I found this on Docker, So let’s start the story……

Hritom Bhattacharya, on medium.com

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 like action checked for an existing like and then wrote a new one without making that check-and-write atomic, so parallel requests all passed the check.

Impact

An attacker could inflate the like count of any content from a single account, and most of those likes could not be removed by others.

What the attacker needed

A free Docker Hub account; ability to intercept and replay requests

How it was found

  1. Log in to your account.
  2. Open Docker Hub and pick any content page.
  3. Turn on Burp interception.
  4. Click the star and intercept the request.
  5. Send the request to Repeater and duplicate it about 20 times.
  6. Use 'send group in parallel', wait for responses, then reload the page.

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 is when a program checks something and then acts on it, but two requests arrive so close together that both pass the check before either is recorded. Here the site was meant to allow one like per account, but firing many requests at once let one account add several likes. The result is inflated like counts that cannot easily be undone.

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.

Similar reports

View all

Same bug class and techniques, clearest first.

Race conditions

The lesson behind this report.

Parallel requests reach a state the code assumed could not happen: a coupon used twice, a limit overrun, a check skipped.