Sanshu Inu Hack
Reported loss
$280K
Other
What happened
The attacker's address:
The affected Memstake contract:
The attacker:
- Created two attack contracts, the first one deposited 2,049B KEANU:
the second one is the attack contract:
- Borrowed a large number of KEANU tokens using the flash loan from UniswapV2, and then deposited the tokens into/withdraws from the Memestake using the second smart contract. Since the KEANU has the deflation mechanism, which burns 2% tokens for each transaction, the real number of tokens deposited into the Memestake is smaller than the value (user.amount) maintained by the Memestake contract. The attacker repeated this process and made the number of KEANU tokens inside the Memestake decrease to a small one (1e-07):
- Invoked the Memestake.updatePool() to update the accMfundPerShare. This value relies on the number of KEANU tokens (which was manipulated in the second step.) Then the attacker obtained a large number of Mfund(~61M):
- Swapped the MFund and KEANU to WETH and deposited stolen funds into Tornado Cash mixer:
The attacker gained 156.51 ETH as profits.
Protocol details
Classification
Token
Protocol Type
Exploit/Other
Affected asset / contract
SANSHU
Protocol links
Website
@SanshuToken
Evidence
- report Report sanshu-inu.medium.com
- report Report blocksecteam.medium.com
Build your security review skills
Work through hands-on labs covering real exploit mechanics, review techniques, and defensive patterns.