Parameter Pollution issue in API resulting $XXX
The API accepted an extra parameter, XPoint, when updating a user profile, and the server stored the supplied value as the user's loyalty points. An attacker could set any number of loyalty points on their own account.
Published on smaranchand.com.np
When it comes regarding API pentesting, I am always eager to test it even though I don’t succeed to find critical issues.
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 profile update endpoint bound all submitted JSON fields to the user object without an allow-list, so an unexpected field for loyalty points was saved.
Impact
An attacker could generate any amount of loyalty points in their own account.
What the attacker needed
An account on the service; ability to intercept the app's API traffic
How it was found
- Intercept the Android app's traffic and find the profile update request.
- Notice that the response includes an XPoint field with an empty value.
- Add the XPoint field with a chosen value to the update request and send it.
- Observe the response showing the chosen XPoint value.
- Log out and back in to confirm the points persist.
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 API is the way an app talks to a server. When you update your profile, the app sends a list of fields, and the server is supposed to accept only the fields it expects. Here the server also accepted an extra field for loyalty points, so a user could give themselves free points.
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.