Yam DAO Hack
What happened
Yam Finance's rebasing logic minted excessive YAM into reserves because of a scaling error. The excess supply made governance unusable, preventing the community from fixing the original contracts through a rescue proposal.
The rebase calculation omitted division by BASE after multiplying initSupply by yamsScalingFactor. Excess reserve minting also broke governance because its voting requirements depended on supply. This was a protocol failure rather than an external attacker draining funds.
How it happened
- The rebase calculated total supply using a scaling factor but omitted the corresponding division.
- The incorrect supply calculation caused excessive reserve minting.
- Governance requirements depended on token supply, so the inflated supply undermined the community's ability to approve changes.
- A rescue proposal was submitted but could not restore governance. The project planned a migration to a new version.
Protocol details
Evidence
Build your security review skills
Work through hands-on labs covering real exploit mechanics, review techniques, and defensive patterns.