Skip to content
Business logic Disclosed report Beginner

Possibility to enumerate and bruteforce promotion codes in Uber iOS App

The promo code redemption endpoint in the Uber iOS app lacked rate limiting, allowing attackers to brute-force and enumerate valid promotion codes. The responses also leaked metadata about the inviter, including their name, country, and profile photo.

r0t Follow

Originally disclosed on HackerOne

Bounty$3,000 Medium View original
  • Paid in 5 months
  • Disclosed after 2.7 years

Summary by the program

Due to the lack of rate limiting on the promo code redemption endpoint, it was possible to enumerate promo codes. The response also leaked metadata about the user, including the country of the user, their name and profile photo.

Thanks, @r0t!

Summary by the researcher

Uber has a feature in the iOS app to apply a promotion code right after we register an account.

Since there was no protection against brute force attacks, we were able to enumerate promotion codes, like in report #125505.

This is a similar bug but leaks more information than #125505:

  • Promo code value
  • Country
  • Inviter’s name
  • Inviter’s picture

The original report as published on HackerOne, by r0t. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

The original is short, so this covers everything it reports, then explains this kind of bug in general: how it works, how to test for it and how it is fixed. The general sections are about the bug class, not this target. Written with AI and checked against the original; the original is the record. 4 min read.

What the report shows

The target is the Uber iOS app, specifically the promotion code redemption feature that appears right after a new account is registered. The researcher, r0t, found that the endpoint accepting a promo code had no protection against repeated attempts, so codes could be enumerated by brute force. The report explicitly links this to an earlier report, #125505, describing it as a similar bug that leaks more information.

The program's own summary states the cause plainly: there was a lack of rate limiting on the promo code redemption endpoint. Because of that, promo codes could be enumerated. The response also leaked metadata about the user, including the country of the user, their name and profile photo.

The researcher lists the data exposed by a successful guess:

  • Promo code value
  • Country
  • Inviter's name
  • Inviter's picture

The report does not include the raw request, the endpoint path, the parameter names, the response body or the number of attempts needed. It also does not describe a fix. The platform records the severity as medium and a bounty of 3,000 USD, and the report was disclosed on 20 November 2018.

Root cause

The mistake is the absence of rate limiting, or any equivalent attempt restriction, on an endpoint that validates a short, guessable secret. A promo code is a low-entropy value, and the redemption endpoint answers whether a given code is valid. With no rate limiting, an attacker can submit many candidates and use the difference between a valid and an invalid response to learn which codes exist. The report points to the missing rate limiting directly; The report does not explain why the inviter metadata was returned..

Impact

An attacker could enumerate promotion codes and, on a hit, learn the code value together with the country, name and profile picture of the person who created or shared it. The response also reveals the country, name and picture of the inviter. The report does not quantify how many codes could be found or what value the codes carried, so the practical ceiling of the attack is not stated.

How this kind of bug works

Any endpoint that checks a secret against user input is a candidate for enumeration if the secret space is small enough to search and the server does not slow the search down. Promo codes, referral codes, gift card numbers, invitation tokens and short reset codes all share this property: they are designed to be typed by humans, so they are short and often structured. If the endpoint returns a distinguishable response for a valid code (a different status, a different body, a different error message, or extra fields), each attempt is an oracle.

Defences work at several layers. Rate limiting per account, per IP and per device reduces throughput. Exponential backoff and temporary lockouts after repeated failures make sustained guessing impractical. CAPTCHAs or proof-of-work raise the cost of automation. Constant-time, uniform responses for valid and invalid input remove the oracle. Finally, keeping the response minimal, returning only whether the code applied and nothing about its owner, limits what a successful guess reveals.

How to test for it

  1. Identify endpoints that accept a short code: signup promo fields, referral redemption, gift cards, invite links, discount codes at checkout.
  2. Capture one valid request and one invalid request and compare status codes, body length, error text and any extra JSON fields. A clear difference is the oracle you need.
  3. Send a burst of invalid codes from the same account and observe whether responses change: a 429, a growing delay, a lockout message or a CAPTCHA all indicate protection. No change after a large number of attempts suggests the endpoint is unprotected.
  4. Repeat from a fresh account and from a different source address to see whether limits are per account, per IP or absent entirely.
  5. If a valid code is available to you, submit it and inspect the full response for metadata about the code's owner.

A positive result is a large number of attempts accepted without throttling, combined with a response that reliably distinguishes valid from invalid codes. Common false positives: a generic error page that looks identical for all inputs but hides a difference in timing or headers; client-side validation that blocks the UI but not the API; and rate limits that exist but are set so high they are not visible in a short test. Confirm the oracle with several attempts before reporting.

How it is fixed

Apply rate limiting and lockouts to the redemption endpoint, keyed on account and on source, with backoff after repeated failures. Add a CAPTCHA or similar challenge once a threshold is crossed. Return a single uniform response for valid and invalid codes, and strip owner metadata from the success response so a hit reveals only that the code applied. Log and alert on high-volume redemption attempts per account.

Hunting notes

These bugs hide in onboarding and checkout flows, where a code field is added for convenience and rarely revisited. Referral and invite systems are common offenders because the code is meant to be shared widely. Recon signals include endpoints with names like redeem, apply, promo, voucher, invite or gift, and mobile app traffic that calls them directly. Mobile clients are worth attention because the API behind the app often lacks the protections added to the web front end.

The original is short, so this covers everything it reports, then explains this kind of bug in general: how it works, how to test for it and how it is fixed. The general sections are about the bug class, not this target. Written with AI and checked against the original; the original is the record. 6 min read.

What happened, in plain words

Uber's iOS app (the iPhone app) has a feature that lets you type in a promotion code just after you create a new account. A promotion code is a short string of letters and numbers that gives you a discount or credit, like a voucher you type at a checkout. The app sends that code to a server, and the server replies whether the code is valid.

The researcher, r0t, found that the server had no limit on how many times you could try. In security terms, there was no rate limiting: nothing slowed down or blocked someone who sent guess after guess. Because nothing limited the attempts, a computer could try many codes. This technique is called brute force, and when the goal is to discover which codes exist, it is called enumeration.

The program's own summary says the cause directly: there was a lack of rate limiting on the promo code redemption endpoint. An endpoint is simply a specific address on a server that accepts a particular kind of request, in the same way a particular counter in a shop handles a particular service. Because nothing capped the attempts, promo codes could be enumerated.

The response also leaked metadata about the user. Metadata here means extra information attached to the answer, beyond the simple yes or no. In this case the reply revealed the country of the user, their name and their profile photo.

The researcher lists the data exposed when a guess turned out to be correct:

  • Promo code value
  • Country
  • Inviter's name
  • Inviter's picture

The report lists the inviter's name and picture among the leaked data. So a successful guess also revealed the country, name and picture of the inviter.

The researcher links this to an earlier report, #125505, calling it a similar bug that leaks more information than that one.

The report does not include the raw request, the endpoint path, the parameter names, the response body or the number of attempts needed. It also does not describe a fix. The platform records the severity as medium and a bounty of 3,000 USD, and the report was disclosed on 20 November 2018.

In general, how this kind of bug works

Any endpoint that checks a secret against what a user types is a candidate for this problem, if the secret is short enough to search through and the server does not slow the search down. Promo codes, referral codes, gift card numbers, invitation tokens and short password reset codes all share this property: they are designed to be typed by humans, so they are short and often follow a pattern. A token, in this context, is a short piece of text that stands in for permission or identity.

If the endpoint gives a different answer for a valid code than for an invalid one, every attempt teaches the attacker something. That reliable difference is called an oracle, by analogy with a person who always answers questions truthfully: you can keep asking and learn the answer bit by bit. The difference might be a different status code (the number a server returns, such as 200 for success or 404 for not found), a different response body, a different error message, or extra fields in the reply.

Defences work at several layers:

  1. Rate limiting per account, per IP address and per device reduces how fast someone can try. An IP address is the numeric address a device uses on a network.
  2. Exponential backoff and temporary lockouts after repeated failures make sustained guessing impractical. Backoff means the server makes you wait longer after each failure.
  3. CAPTCHAs or proof-of-work raise the cost of automation. A CAPTCHA is the puzzle that is easy for a person and hard for a program.
  4. Uniform responses for valid and invalid input remove the oracle, so a guess tells the attacker nothing extra.
  5. Keeping the response minimal, returning only whether the code applied and nothing about its owner, limits what a successful guess reveals.

In general, how to test for it

  1. Identify endpoints that accept a short code: signup promo fields, referral redemption, gift cards, invite links, discount codes at checkout.
  2. Capture one valid request and one invalid request and compare status codes, body length, error text and any extra JSON fields. JSON is a common text format for data exchanged between apps and servers. A clear difference is the oracle you need.
  3. Send a burst of invalid codes from the same account and observe whether responses change: a 429 (the status code for too many requests), a growing delay, a lockout message or a CAPTCHA all indicate protection. No change after a large number of attempts suggests the endpoint is unprotected.
  4. Repeat from a fresh account and from a different source address to see whether limits are per account, per IP or absent entirely.
  5. If a valid code is available to you, submit it and inspect the full response for metadata about the code's owner.

A positive result is a large number of attempts accepted without throttling, combined with a response that reliably distinguishes valid from invalid codes. Common false positives: a generic error page that looks identical for all inputs but hides a difference in timing or headers; client-side validation that blocks the interface but not the API; and rate limits that exist but are set so high they are not visible in a short test. Client-side validation means checks done inside the app or browser, which an attacker can bypass by talking to the server directly. Confirm the oracle with several attempts before reporting.

In general, how it is fixed

Apply rate limiting and lockouts to the redemption endpoint, keyed on account and on source, with backoff after repeated failures. Add a CAPTCHA or similar challenge once a threshold is crossed. Return a single uniform response for valid and invalid codes, and strip owner metadata from the success response so a hit reveals only that the code applied. Log and alert on high-volume redemption attempts per account.

In general, where to look

These bugs hide in onboarding and checkout flows, where a code field is added for convenience and rarely revisited. Referral and invite systems are common offenders because the code is meant to be shared widely. Recon signals include endpoints with names like redeem, apply, promo, voucher, invite or gift, and mobile app traffic that calls them directly. Mobile clients are worth attention because the API behind the app often lacks the protections added to the web front end.

Glossary

  • Endpoint: a specific address on a server that accepts a particular kind of request.
  • Promotion code: a short string of letters and numbers that gives a discount or credit when redeemed.
  • Rate limiting: a server rule that caps how many requests can be made in a period of time.
  • Brute force: trying many guesses automatically until one works.
  • Enumeration: systematically discovering which items, such as codes, exist.
  • Metadata: extra information attached to a response beyond the main answer.
  • Inviter: the person who created or shared a code.
  • Token: a short piece of text that stands in for permission or identity.
  • Oracle: a reliable difference in responses that lets an attacker learn from each attempt.
  • Status code: the number a server returns to describe the outcome, such as 200 or 404.
  • IP address: the numeric address a device uses on a network.
  • Backoff: making the client wait longer after each failure.
  • Lockout: temporarily blocking an account or source after repeated failures.
  • CAPTCHA: a puzzle that is easy for a person and hard for a program.
  • Proof-of-work: a small computational task a client must complete before a request is accepted.
  • JSON: a common text format for data exchanged between apps and servers.
  • Client-side validation: checks done inside the app or browser, which can be bypassed by talking to the server directly.
  • API: the interface a program uses to talk to a server.
  • False positive: a test result that looks like a bug but is not one.

More by r0t

View all

1 more disclosed report, best first.

More from Uber

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Business logic flaws

The lesson behind this report.

The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.