Exploiting OTP with IP Rotation on a Flutter App: Bypassing Rate
The password reset flow used a 4-digit OTP and blocked an IP after 30 failed attempts, but the block lasted only one minute. An attacker could rotate through many proxies to brute-force the OTP within its 10-minute validity and obtain a UUID to reset any user's password.
Published on 0xhussein.medium.com
My name is Hussein Ali Taha, a cybersecurity researcher specializing in mobile and web application security. This report details a vulnerability I discovered in a Flutter application.
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 OTP was too short (4 digits) and the rate limit was per-IP with a short block duration, allowing bypass via IP rotation.
Impact
An attacker could brute-force the OTP and obtain a UUID to reset the password of any user registered in the application within minutes.
What the attacker needed
Victim's phone number; access to many proxies; ability to intercept app traffic
How it was found
- Use the Forgot Password feature and enter the victim's phone number to trigger an OTP.
- Capture the OTP verification request and send it to Intruder.
- Configure Intruder to try all 4-digit codes from 0000 to 9999.
- Observe that the server blocks the IP after 30 attempts for one minute.
- Collect and filter a list of fast proxies.
- Run a script that rotates proxies, sending up to 30 attempts per IP, and stops on a 200 response.
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 one-time password (OTP) is a short code sent to your phone to prove it's you. Here the code was only 4 digits, so there are just 10,000 possible codes. The app tried to stop guessing by blocking an IP address after 30 wrong tries, but the block lasted only a minute, so an attacker could switch to a different IP address and keep guessing until they found the right code.
What is Account takeover?
Getting into someone else's account through a flaw in sign-in, password reset, second factor, single sign-on or session handling.