How I Hacked the IRCTC eCatering Portal
The IRCTC eCatering portal accepted a customerid parameter from the client without verifying it belonged to the logged-in user, so an attacker could change it to another valid customer ID and place food orders on that person's PNR or profile. This could cause financial loss and false allegations against the victim.
Published on medium.com
IRCTC (Indian Railway Catering and Tourism Corporation) is a public sector undertaking that provides ticketing, catering, and tourism services for Indian Railways. Established in 1999 under the Ministry of Railways, it was listed on NSE and BSE in 2019, with the Government holding 67% ownership.
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 server trusted the client-supplied customerid parameter without checking that it matched the authenticated user's own ID.
Impact
An attacker could place food orders on behalf of any IRCTC user or PNR holder, causing financial loss and false allegations; the report says the issue has been patched.
What the attacker needed
A valid IRCTC account; knowledge of another valid customer ID; an intercepting proxy
The fix
The vulnerability was fixed after being reported to CERT-In and acknowledged by IRCTC.
How it was found
- Log in to the IRCTC eCatering portal with a valid account and start a food order.
- Capture the request sent when clicking Save & Proceed using an intercepting proxy.
- Change the customerid parameter to another valid customer ID and forward the request.
- The server processes the order under the other user's PNR and profile without their knowledge.
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.
When you order food on a website, the site usually checks that the account making the request is the same account the order is for. Here, the site trusted a number sent by the browser (the customer ID) and did not check it against the logged-in user. So someone could swap in another person's ID and order food charged to them.
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.