Authorization disclaimer. This walkthrough is limited to the intentionally vulnerable PortSwigger Web Security Academy lab linked below. Test only systems you own or are explicitly authorized to assess.
Overview
The POST /cart body accepts a signed quantity. A negative quantity for a second product offsets one jacket while a carefully tuned positive cart total still passes checkout.

Lab objective/setup
This intentionally vulnerable Academy exercise isolates high-level logic vulnerability. The supplied accounts and endpoints are used to reproduce only the source note evidence for high-level logic vulnerability; all request changes remain inside this Academy instance.
What I observed
The POST /cart body accepts a signed quantity. A negative quantity for a second product offsets one jacket while a carefully tuned positive cart total still passes checkout.



Why it is vulnerable
Quantity validation is incomplete and the total calculation permits values outside the business domain.
Walkthrough in the authorized PortSwigger lab
- Capture the baseline request for high-level logic vulnerability and record the response that represents the intended lab workflow.
- Replay the recorded mutation that exposes high-level logic vulnerability, keeping the session and other fields unchanged.
- Confirm the high-level logic vulnerability signal in the response before applying the next source-documented operation.
- Complete the Academy objective using only the confirmed high-level logic vulnerability behavior and the supplied synthetic account or product data.




Verification
The final capture shows the Academy marking the high-level logic vulnerability exercise as solved after the documented request sequence. No testing was performed outside the isolated lab.

Impact and defensive lesson
The evidence demonstrates the concrete risk of high-level logic vulnerability: a server-side trust decision can be bypassed through the exact input or workflow shown in this lab. For high-level logic vulnerability, the server must enforce the exact invariant violated in the captured sequence and regression-test that mutation alongside the normal path.