$$$ How I Discovered a Business Logic Vulnerability That Allowed
The checkout process allowed a client to change the shipping country parameter, which reduced the shipping fee and removed tax without the server recalculating the total. An attacker could pay less than the intended amount for an order.
Published on medium.com
أَوَلَ� ْ يَعْلَ� ُوا أَنَّ اللَّهَ يَبْسُطُ الرِّزْقَ لِ� َن يَشَاءُ وَيَقْدِرُ ۚ إِنَّ فِي ذَٰلِكَ لَآيَاتٍ لِّقَوْ� ٍ يُؤْ� ِنُونَ [ الز� ر: 52]
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 did not validate or recalculate the shipping cost and tax based on the actual destination, relying instead on client-supplied data.
Impact
An attacker could pay reduced shipping fees and avoid tax, potentially causing financial loss to the store.
What the attacker needed
A user account on the store; ability to intercept HTTP requests
The fix
The server should validate and recalculate shipping costs and taxes based on the actual destination, not client-supplied data.
How it was found
- Intercept the checkout request to the place-order endpoint.
- Locate the shippingCountry parameter in the request.
- Change the shippingCountry to a country with lower shipping fees.
- Observe that the shipping price drops and tax is removed while the actual destination remains unchanged.
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 buy something online, the website calculates shipping and tax based on where you say you live. This report shows that the website trusted the information sent by the user's browser without checking it again on the server. So a user could say they live in a cheaper country, pay less, but still get the item delivered to their real address.
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.