While num implies an integer, the HTTP protocol does not enforce data types. An attacker can send: add-cart.php?id=200&num=1.9999
When a user clicks "Buy Now," the browser sends a request like this: ://example.com The server then: Receives the ID 123 . add-cart.php num
"Infinite stock," Elias whispered, his fingers flying across the mechanical keyboard. If someone could "add" negative items, they weren't buying; they were injecting inventory into the system—or worse, triggering a refund for an item they never owned. While num implies an integer, the HTTP protocol