Wiener DOGE Hack

Reported loss $30K
BNB Chain
Rounding Error

What happened

On 25 April 2022 an attacker drained about 78 BNB (roughly $30,000) from the WDOGE/WBNB PancakeSwap pool of Wiener DOGE, a deflationary BEP-20 token on BNB Chain. WDOGE burned 4% of every transfer, and the contract did not exclude the liquidity pair from that fee when the pair itself was the sender. By pushing tokens into the pair and pulling them back out with skim(), the attacker made the pair pay the burn out of its own balance, shrank the pool's WDOGE reserve, and then sold WDOGE back into the distorted pool for more BNB than was borrowed.

How it happened

  1. The attacker flash-swapped 2,900 WBNB from the PancakeSwap BUSDT/WBNB pair.
  2. The 2,900 WBNB was swapped into the WDOGE/WBNB pair for about 6.6 trillion WDOGE.
  3. A large WDOGE amount was sent straight to the pair, leaving it holding more WDOGE than its recorded reserve.
  4. The attacker called skim() to take the excess back. Because the pair was the sender, the 4% burn came out of the pair's balance, so it ended up with fewer WDOGE than before.
  5. sync() wrote the reduced WDOGE balance into the reserves, making WDOGE scarce and expensive in the pool.
  6. The attacker sold the remaining WDOGE into the pair for about 2,978 WBNB, repaid the flash swap, and kept about 78 BNB.

Protocol details

Classification Token & Share Accounting
Protocol Type DeFi Protocol
Implementation language Solidity

Build your security review skills

Work through hands-on labs covering real exploit mechanics, review techniques, and defensive patterns.