Skip to content
Race condition Write-up Intermediate

Introduction

The endpoint that associates a user with an ID had a 10-attempt limit, but the backend counter was not protected against concurrent requests. By sending many requests in parallel, an attacker could bypass the limit and brute-force IDs without lockout.

chorfimajd22 Follow

Published on medium.com

This was one of my earlier discoveries as a hacker under the name ValidByAccident — a case that showed me how concurrency issues can slip under the radar even in mature systems.

ValidByAccident, 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 attempt counter was read and updated without locking or atomic operations, so concurrent requests overwrote each other's increments.

Impact

The 10-attempt limit could be bypassed, enabling ID enumeration or guessing and potentially unauthorised associations between users and vendor accounts; the text notes that valid IDs may still be hard to obtain.

What the attacker needed

An account on the target site; ability to send parallel requests

The fix

The text says the issue was fixed but does not describe the fix; it should be fixed by making the counter update atomic or properly locked.

How it was found

  1. Log in and open the feature that associates a user with an ID.
  2. Capture the POST request that submits the ID.
  3. Clone the request several times and send the copies in parallel.
  4. Observe that the server counts only one attempt despite the concurrent requests.

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 several requests reach the server at the same moment and the code that updates a shared value, like an attempt counter, does not handle them one at a time. Here the server counted only one attempt even though many arrived together, so the 10-try limit did not stop repeated guessing of IDs.

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.

More by chorfimajd22

View all

1 more disclosed report, best first.

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.