Idor Account Takeover How I Secured Personal Information Pii Of 5 17m Electricity Consumers
Two unauthenticated API endpoints allowed anyone to fetch consumer numbers by mobile number and then full consumer details by consumer number, exposing PII of millions. Separately, the login flow set a session cookie equal to the user's mobile number, so an attacker who knew a victim's mobile number could manipulate the OTP verification response to log in as them.
Published on infosecwriteups.com
Hello, my name is Biraj Baishya, aka brutexploiter. I am an independent security researcher, a full-time bug bounty hunter, and a mechanical engineer.
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 missing authentication and authorization checks on API endpoints, plus using a predictable value (mobile number) as a session cookie and trusting client-side response manipulation.
Impact
An attacker could obtain personal information (name, email, mobile, address, PAN, voter ID, Aadhaar) of millions of consumers and take over accounts without OTP, though the text notes the vulnerabilities were fixed.
What the attacker needed
Knowledge of victim's mobile number; no authentication needed for API endpoints; proxy tool to intercept and modify responses
The fix
The vulnerabilities were fixed according to the disclosure timeline.
How it was found
- Access the APDCL login page and click on login.
- Enter a valid user account's mobile number and captcha, then click send OTP.
- Turn on intercept for both request and response using a proxy tool.
- Enter any wrong or random six-digit OTP and click login.
- Forward the captured request, then modify the response to redirect to the dashboard and set a cookie with the victim's mobile number.
- Forward the manipulated response and turn off intercept to gain access.
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.
An IDOR (Insecure Direct Object Reference) is when a website lets you access someone else's data just by changing a number or identifier in a request, without checking if you are allowed. Here, two API endpoints had no login check at all, so anyone could look up electricity consumers by phone number or consumer number. In the second bug, the login system used the user's mobile number as the session cookie, so an attacker could fake a successful login by editing the server's response.
What is IDOR?
One user can read or change another user's data, usually by changing an identifier the server trusts without checking who is asking. One of the most paid bug classes on web programs.