On December 4, 2024, Vestra_DAO was hacked due to a logic error in in the staking contract's unStake()
function. The function failed to check whether a staking position was still active before allowing it to be unstaked, enabling the attacker to repeatedly claim yield from an already unstaked position. Exploiting this flaw, the attacker prepared for a month by initially staking VSTR tokens, then calling the unStake()
function multiple times to siphon yield repeatedly. The attack drained approximately $500,000 worth of tokens from the Vestra DAO contract.
VSTR is a token that provides semi-decentralized, Web2+Web3 hybrid services, launched and developed by the NFT community "CMLE" (Crypto Monster Limited Edition). Simultaneously, it operates as a Decentralized Autonomous Operation (DAO) project providing DeFi (Decentralized Finance) solutions. The project, built on the Ethereum platform, adheres to ERC20 standards.
Attack Transactions: 0x213991ca, 0xa0dcf9b
Vulnerable Contract: 0x8A30d6
Attacker Address: 0x954386
Attacker Contract Address: 0x81AD99
After lock period is over, the attacker used the same account to call the unStake()
function.
This action returned the initial 500,000 VSTR along with 20,000 VSTR in yield, marking the staking position as isActive = false.
Due to a missing check for the isActive status in the unStake() function, the attacker could repeatedly call unStake()on the same position.
To prevent an underflow in data.totalStaked
and data.countUser
, the attacker created new accounts or smart contracts.
These fresh accounts staked 500,000 VSTR each, ensuring the contract’s staking balance remained sufficient.
data.totalStaked
and data.countUser
value.See the funds flow here:
Vestra DAO addressed the hack incident via their official Twitter (X) account:
unStake()
function checks whether a staking position is still active before proceeding.Choosing a reputable audit firm like QuillAudits ensures that your protocol undergoes rigorous scrutiny from experienced security professionals. QuillAudits specializes in uncovering critical vulnerabilities and providing actionable remediation strategies. Our expertise helps safeguard your project from attacks, ensuring that security issues are addressed proactively.
Join 1000+ leaders who secured themselves from losing Billion Dollars.
Get Pure Alpha Straight to Your Inbox. Miss this, and you’re missing out.
Insider Secrets - Delivered Right to You. Subscribe now.