Skip to content
Race condition Write-up Intermediate

How a Race Condition Turned a Simple Feedback Form Into a $700 Bounty

A feedback form enforced a one-minute cooldown between submissions, but when multiple identical requests were sent concurrently, all were accepted instead of being rate-limited. An attacker could submit many feedback entries at once, triggering repeated notification emails to the administrator.

Ekansh Choudhary Follow

Published on medium.com

Bug Bounty

Ekansh Choudhary, 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.

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 5 min read.

Context

The target was a bug bounty application with an authenticated feedback submission feature. Any logged-in user could enter feedback and submit it, and the server processed the request normally. The only visible protection was a cooldown: after one submission, a second submission within the restricted period was rejected with HTTP/2 429 Too Many Requests, and the response indicated that the user had to wait before submitting again. The researcher describes this as a 1-minute cooldown between feedback submissions.

That defence looked correct from a normal user's point of view: wait for the cooldown and the request succeeds, submit too soon and you get 429. The report's point is that this sequential behaviour hid a race condition in the rate-limit check.

Setup

The report does not name the program, the application or the endpoint. The preconditions it does state are:

  • An authenticated user account on the target application.
  • Access to the feedback submission functionality.
  • Burp Suite, used to capture the request, duplicate it and send the copies concurrently.

No parameter names, headers, versions or request bodies are reproduced in the report, so none are given here.

Finding it

The researcher's methodology was to understand how the endpoint handled repeated submissions. The request was captured in Burp Suite and sent again immediately after the first successful submission. The second request returned:

HTTP
HTTP/2 429 Too Many Requests

The response also indicated that the user needed to wait before submitting feedback again. The application therefore had some form of rate limiting or cooldown mechanism, which the researcher treats as a good sign from a defensive perspective: the application was not blindly accepting repeated requests, it knew feedback had just been submitted and prevented another submission within the restricted period.

Figure 1: Sequential feedback submission triggering the application’s 1 minute cooldown. From the original on medium.com

Figure 1 shows the sequential submission: the first request succeeds, the immediate second one is answered with 429.

The expected flow is a simple state machine: a submission is accepted, the cooldown starts, and any request arriving inside that window is rejected.

Figure 2: Application’s Logic From the original on medium.com

Figure 2 illustrates that logic. Rate limiting is usually tested in a straightforward way: send a request, send another, send another, for example with Burp Intruder in sniper mode, and watch for the 429. The researcher instead focused on a different dimension: concurrency. Web applications do not necessarily process requests sequentially, and multiple requests can reach the server at almost exactly the same time. If the rate-limit check is not designed to handle that, several requests might pass through before the application's state is updated.

Figure 3: Difference between Sequencial and Concurrent Requests. From the original on medium.com

Figure 3 contrasts sequential and concurrent request handling, which is the distinction the whole test rests on.

Exploitation

Step 1: Confirm the sequential cooldown

A feedback submission was sent and succeeded. An identical request sent immediately afterwards was rejected:

HTTP
HTTP/2 429 Too Many Requests

This established the baseline: the rate limit exists and works when requests arrive one after another.

Step 2: Duplicate the request without changing it

The request was duplicated in Burp Suite. Nothing was modified: not the parameters, not the authentication, not the cooldown value. Only the timing of the requests changed. The question was whether the application would treat 11 requests arriving at nearly the same time as separate requests, or whether the rate limiter would stop them.

Step 3: Send 11 requests concurrently

The 11 identical requests were sent concurrently, in group parallel.

Figure 4: Eleven identical feedback requests prepared for concurrent execution. From the original on medium.com

Figure 4 shows the eleven identical feedback requests prepared for concurrent execution.

Instead of one successful response followed by a series of 429 responses, the requests were accepted. All 11 were processed within the same moment, and the responses showed:

HTTP
HTTP/2 200 OK

with the application's normal response text:

Text
Thank you! Your feedback has been sent.
From the original on medium.com
Figure 5–6: Representative responses from the concurrent request group. Tabs 24 through 34 represent the 11 parallel requests; the screenshot shows requests 24, 27, and 30 as examples, all returning HTTP 200 OK.

Figures 5 and 6 show representative responses from the concurrent group. Tabs 24 through 34 are the 11 parallel requests; the screenshots show requests 24, 27 and 30 as examples, all returning HTTP 200 OK. This was completely different from the sequential testing.

Step 4: Confirm the requests were actually processed

A 200 response alone does not prove the workflow ran. The feedback submission triggered an email notification, and the concurrent submissions produced multiple notification emails, which confirmed that the application was not merely returning 200 OK: the underlying feedback workflow was executed repeatedly. The same behaviour also triggered notifications to the application's administrator. The administrator's mailbox is not included in the report.

Figure 7: Multiple notification emails generated from the concurrent submissions. From the original on medium.com

Figure 7 shows the multiple notification emails generated from the concurrent submissions.

Root cause

Conceptually, the application had to perform four steps per submission: check the rate limit, process the request, update the state, and start the cooldown. With concurrent requests, several requests could reach the check before the state was safely updated:

Text
Request A ─┐
Request B ─┤ → Check → Allowed → Process
Request C ─┘

That is the race. The rate limit was not missing: sequential requests were correctly blocked with HTTP 429. It simply was not race-safe. Conceptually, the check and the state update are not atomic with respect to each other, so requests arriving inside the same window may all observe the pre-submission state and be allowed through. The report describes this conceptually and does not show the server-side code, so the exact implementation is not stated.

Impact

The researcher demonstrated that a single authenticated user could bypass the one-minute cooldown and have 11 feedback submissions processed at once, producing multiple notification emails, including notifications to the application's administrator. The report does not quantify what an attacker could achieve beyond this: it does not state how many requests could be pushed through in one burst, whether the feedback content is attacker-controlled in a way that matters, or what the notification volume could reach. The demonstrated effect is repeated execution of a state-limited workflow and the resulting multiple notification emails, including to the administrator's mailbox.

The report frames the wider lesson as applying to any decision made on shared state and timing, not only to financial logic such as redeeming a coupon twice, withdrawing money simultaneously, checking and modifying a balance, or purchasing limited inventory.

Fix

The report states that the rate limit must be race-safe, not only correct for sequential traffic, but does not name a specific mechanism.

Variants to test

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 11 min read.

What happened, in plain words

A security researcher was testing a website that pays people for finding its security mistakes, a setup called a bug bounty programme. While exploring the site, he found a simple feedback form: a box where a logged-in user can type a comment and send it to the company. The site had a rule that you could only send feedback once a minute. If you tried again too soon, the site said no with an error message.

Most people would test that rule by sending one message, then another, then another, and seeing the error appear. The researcher did that, and the rule worked. But he asked a different question: what if several messages arrive at the server at exactly the same moment, rather than one after another? When he sent eleven identical messages at once, the site accepted all eleven. Each one was processed, and the submissions generated multiple email notifications. The one-minute rule had been bypassed without changing a single thing in the request, only the timing.

This kind of flaw is called a race condition. Conceptually, the site checked "has this user sent feedback recently?" and then recorded the new feedback as a separate step. When many requests arrive together, they all ask the question before any of them has recorded an answer, so they all get a yes.

The basics you need first

Before walking through the test, here are the ideas that come up, explained from scratch.

A web application is a program that runs on a company's computer (the server) and that you use through your browser. When you click a button, your browser sends a small message to the server asking it to do something, and the server sends a message back.

A request and a response are those two messages. The request is what your browser sends ("please save this feedback"). The response is what comes back ("done" or "not allowed"). Think of it like posting a letter and getting a reply.

An API endpoint is the specific address on the server that handles one kind of action. If the website were a building, the endpoint would be a particular service desk: one desk for feedback, one for login, one for payments. Each desk has its own rules.

HTTP status codes are short numbers in the response that tell you what happened. 200 OK means the request succeeded. 429 Too Many Requests means the server is refusing because you have asked too often. You have probably seen a 404 page when a link is broken; that is the same idea.

Authentication means proving who you are, usually by logging in with a username and password. Once you are logged in, your browser holds a small piece of proof, often called a session cookie or token, which it sends with every request so the server knows it is still you. Without it, the server would treat every request as a stranger.

Rate limiting is a rule that says "you may only do this so many times in a given period". It protects servers from being flooded and stops people from abusing features. A cooldown is a simple form of rate limiting: after you do something, you must wait before doing it again.

A race condition is a bug that appears when two things happen at almost the same time and the program is not prepared for it. A everyday comparison: two people reach for the last seat on a train at the same moment. Each looks, each sees the seat free, each sits down, and now there are two people in one seat. Neither did anything wrong; the problem is that "check if the seat is free" and "take the seat" were not a single, indivisible action.

Concurrency means several things happening at overlapping times rather than strictly one after another. Sequential means one after another: finish the first, then start the second.

Burp Suite is a tool used by security testers. It sits between your browser and the website and lets you see, pause, change and resend the requests your browser makes. It also has a feature to send many copies of the same request at the same moment, which is exactly what this test needed. You do not need to install anything to follow the story; just know that it is a workshop for inspecting and replaying requests.

The feedback feature

The researcher was exploring the application as a logged-in user. He found a feedback form: you type something, you press submit, and the server saves it. Nothing unusual.

His habit, as a tester, is to ask how a feature behaves when you use it repeatedly. So he captured the feedback request in Burp Suite and sent it once. It worked. Then he sent the exact same request again straight away. This time the server replied:

HTTP
HTTP/2 429 Too Many Requests

Line by line: HTTP/2 is the version of the language the browser and server use to talk; you can read it as "this is a web response". 429 is the status code meaning "too many requests". Too Many Requests is the human-readable name for that code. So the whole line says: the server understood, but it is refusing because you have asked too often.

The response also told him he needed to wait before submitting feedback again. So the application had a cooldown. From a defender's point of view, that is good news: the site was not blindly accepting every request. It remembered that feedback had just been sent and blocked a second attempt inside the waiting period.

Figure 1: Sequential feedback submission triggering the application’s 1 minute cooldown. From the original on medium.com

Figure 1 shows the sequence: the first submission succeeds, and the immediate second one comes back with the 429.

The expected behaviour is simple. You submit, the cooldown starts, and anything that arrives during the cooldown is turned away. The researcher describes this as a one-minute cooldown between feedback submissions.

Figure 2: Application’s Logic From the original on medium.com

Figure 2 illustrates that logic as a flow: submit, start the timer, reject anything that arrives too soon.

At this point, a normal user would be satisfied. Wait a minute and it works; try too soon and you get the error. Many testers would write "rate limiting present" in their notes and move on.

The question that changed everything

Rate limiting is usually tested in a very plain way: send a request, send another, send another, and watch for the 429 to appear. The researcher mentions doing this with Burp Intruder in sniper mode, which is a Burp feature that fires a series of requests one after another so you can watch the responses.

But there is another dimension that is easy to miss: concurrency. Web applications do not necessarily handle requests strictly one at a time. Several requests can reach the server at almost exactly the same moment. That makes these two situations fundamentally different:

Figure 3: Difference between Sequencial and Concurrent Requests. From the original on medium.com

Figure 3 contrasts requests arriving one after another with requests arriving together, which is the distinction the whole test rests on.

Why does this matter? Imagine the server's rule is written as two separate steps: first check whether the user is in a cooldown, then, if not, save the feedback and start the cooldown. If eleven requests arrive together, all eleven can reach the check before any of them has saved anything. Each one looks at the state, sees no recent feedback, and is allowed through. The cooldown is only recorded afterwards, too late to stop the others.

That was the behaviour the researcher wanted to investigate.

Sending everything at once

Instead of sending another request normally, he duplicated the captured request in Burp Suite and prepared to send many identical copies at the same time.

He changed nothing. Not the parameters (the pieces of data inside the request, such as the feedback text), not the authentication (the cookie or token proving who he was), not the cooldown value. The only thing that changed was the timing.

The question was simple: would the application treat eleven requests arriving at nearly the same moment as eleven separate requests, or would the rate limiter stop them?

The race against the server

The result was unexpected. He sent eleven requests concurrently, in a group parallel, meaning all at once rather than one after another.

Figure 4: Eleven identical feedback requests prepared for concurrent execution. From the original on medium.com

Figure 4 shows the eleven identical feedback requests lined up, ready to be fired together.

Instead of one success followed by a run of 429 responses, the requests were accepted. All eleven were processed within the same moment, and the responses came back as:

HTTP
HTTP/2 200 OK

Line by line: HTTP/2 is again the protocol version, and 200 is the status code meaning the request succeeded. OK is its name. So the server was saying yes to all of them.

The body of the response was the application's normal success message:

Text
Thank you! Your feedback has been sent.

This is the text a user sees after a normal, single submission. Getting it eleven times at once was completely different from what the sequential test had shown.

From the original on medium.com
Figure 5–6: Representative responses from the concurrent request group. Tabs 24 through 34 represent the 11 parallel requests; the screenshot shows requests 24, 27, and 30 as examples, all returning HTTP 200 OK.

Figures 5 and 6 show representative responses from the concurrent group. Tabs 24 through 34 in Burp are the eleven parallel requests; the screenshots show requests 24, 27 and 30 as examples, all returning HTTP 200 OK.

Proving it really happened

A 200 OK response is a promise, not proof. A server could return success while quietly doing nothing. The researcher wanted to confirm the feedback workflow had actually run, not just that the responses looked happy.

It had. Each feedback submission triggers an email notification, and the concurrent submissions produced multiple notification emails. That confirmed the application was not merely returning 200 OK: the underlying workflow was executed repeatedly. The same behaviour also triggered notifications to the application's administrator. Because this was a real bug bounty target, the administrator's mailbox is not shown in the report.

Figure 7: Multiple notification emails generated from the concurrent submissions. From the original on medium.com

Figure 7 shows the multiple notification emails generated by the concurrent submissions.

Why it worked

Behind the scenes, the application had to do four things for each submission: check the rate limit, process the request, update the state, and start the cooldown. With concurrent requests, several requests could reach the check before the state was safely updated:

Text
Request A ─┐
Request B ─┤ → Check → Allowed → Process
Request C ─┘

Line by line: the three lines on the left are three separate requests arriving at the same time. The arrows show them all joining the same path: they all reach the check, all are allowed, and all are processed. None of them sees that another one has already been let through.

That is the race. The rate limit was not missing: sequential requests were correctly blocked with HTTP 429. It simply was not race-safe. The check and the state update are not atomic with respect to each other. Atomic here means "happens as one indivisible step, so nothing can slip in between". Because they are separate steps, requests arriving in the same window all see the state as it was before any submission and are all allowed through. The report explains this conceptually and does not show the server-side code, so the exact implementation is not stated.

It was not just eleven happy responses

The researcher stresses this point: the interesting part was not that the application had no rate limit. It had one. The interesting part was that the rate limit worked sequentially but failed under concurrency.

Race conditions are not only about money

When people hear "race condition", they often think of financial examples:

  • Redeeming the same coupon twice.
  • Withdrawing money simultaneously.
  • Checking and modifying an account balance.
  • Purchasing limited inventory.

But the underlying problem is broader. A race condition can appear anywhere an application makes a decision based on shared state and timing. Shared state means information that several requests can read and change, such as "when did this user last send feedback?". Timing means the order and overlap in which those requests arrive. In this case, the feature was a simple feedback form.

What this means for you as a tester

The lesson is a habit of mind: keep asking what happens if the requests do not arrive one after another. The researcher notes that he could not connect the dots while testing, but later everything made sense. The mentality to keep questioning and look beyond what is immediately in front of you is what matters.

What the report does not say

The report does not name the programme, the application or the endpoint, and it does not reproduce any parameter names, headers, versions or request bodies. It does not describe a fix or say that one was applied. It does not quantify what an attacker could achieve beyond the demonstrated eleven submissions and the resulting notification emails.

Glossary

  • API endpoint: the specific address on a server that handles one kind of action, like a service desk for one task.
  • Atomic: happening as one indivisible step, so nothing can slip in between.
  • Authentication: proving who you are, usually by logging in.
  • Bug bounty programme: a scheme where a company pays researchers for finding and reporting security flaws.
  • Burp Intruder: a Burp Suite feature that sends a series of requests, often one after another, so you can watch the responses.
  • Burp Suite: a tool that sits between your browser and a website so you can inspect, pause, change and resend requests.
  • Concurrency: several things happening at overlapping times rather than strictly one after another.
  • Cooldown: a rule that after you do something you must wait before doing it again.
  • HTTP status code: a short number in a response saying what happened, such as 200 for success or 429 for too many requests.
  • Parameter: a piece of data inside a request, such as the text of a feedback message.
  • Race condition: a bug that appears when two things happen at almost the same time and the program is not prepared for it.
  • Rate limiting: a rule limiting how often something may be done in a given period.
  • Request: the message your browser sends to a server asking it to do something.
  • Response: the message a server sends back.
  • Sequential: one after another, finishing each before starting the next.
  • Session cookie or token: a small piece of proof your browser holds after logging in and sends with each request so the server knows it is you.
  • Shared state: information that several requests can read and change, such as when a user last sent feedback.
  • Sniper mode: a Burp Intruder mode that fires requests one after another.
  • Web application: a program running on a company's server that you use through your browser.

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.