Cyber Risks · PortSwigger Research

Lab: High-level logic vulnerability

Summary: PortSwigger's Web Security Academy lab describes a purchasing workflow that fails to validate user input: the quantity in a POST /cart request can be set to an arbitrary integer, and a negative quantity larger than the cart's contents forces the cart to hold a negative number of units. The total price then becomes negative, and adding a leather jacket alongside a negative quantity of another item brings the order below the available store credit.

Bottom line: The flaw is a single unvalidated parameter in the cart request, and it lets an attacker turn store credit into a negative total that pays for a higher-priced item. Any checkout flow that trusts a client-supplied quantity without checking its sign or bounds carries the same exposure.

Read the original at PortSwigger Research ↗

Topics
Vulnerabilities & Patching
Related