↓ Skip to main content

“What’s more, the price is calculated by the client(!) by multiplying the unit price of whatever is being purchased by the quantity being ordered.”

Dan Mayermayer.cool ↗

MTG Arena’s server checked the price by repeating the client’s math, overflow and all, in a 32-bit int. Order 21,474,837 packs at 200 gems each and the total wraps around to almost nothing. A new account’s 250 free gems bought over $20 million in cards, and maxed-out packs refunded gems for the next set. Wizards of the Coast patched it after the report. The validation copied the bug it was supposed to catch.