HomeAboutWhat is web3?FAQLicenseTwitterMastodonBlueskyInstagramThreadsRSSLeaderboardGlossaryContributeNewsletterStore

Archived tweet

Back

Tweet by coffeexcoin:

The 
@SSS_HQ
 $SSS LP was just drained on blast because their token contract has a bug where transferring your entire balance to yourself doubles it.

The order of operations decrements the balance for "from" and then sets the balance for "to" - if these are the same address, the "toBalance" does not take into affect the decrement of "amount" and just overwrites the balance with the initial balance + transferred amount.
Attacker was able to get 1310 ETH from the LP by doubling their balance repeatedly and then selling it all

https://blastscan.io/tx/0x80012bf784b83baaf28f5549a9f233cae5f70be7afcd8f594dc757d431ed93c4…

https://blastscan.io/tx/0x62e6b906bb5aafdc57c72cd13e20a18d2de3a4a757cd2f24fde6003ce5c9f2c6…

https://blastscan.io/tx/0xac3400e3d536ac23c10fdd2c06e1faf8d5de5b797df8433e9b5ab74b102a4e35… 
Tweeted at 11:26 AM · Mar 21, 2024

Tweet #1

Image #1:

Image

Links:

  • https://blastscan.io/tx/0x80012bf784b83baaf28f5549a9f233cae5f70be7afcd8f594dc757d431ed93c4
  • https://blastscan.io/tx/0x62e6b906bb5aafdc57c72cd13e20a18d2de3a4a757cd2f24fde6003ce5c9f2c6
  • https://blastscan.io/tx/0xac3400e3d536ac23c10fdd2c06e1faf8d5de5b797df8433e9b5ab74b102a4e35

Text is licensed under a Creative Commons Attribution 3.0 Unported License. All attribution can be found on the attribution page.

Source code | Contribute