The withdraw function in the TokenManager contract is vulnerable to a reentrancy attack. This vulnerability allows malicious users to exploit the contract by repeatedly calling the withdraw function
The withdraw function performs token transfers, including transferring native tokens and ERC20 tokens, without implementing a reentrancy guard. A malicious contract could call the withdraw function to withdraw native token, and within the same transaction, reenter the withdraw function. This would allow the attacker to drain more tokens than they are entitled to.
reentrancy attack could result in the attacker draining all native tokens from the pool
Manual
Use the nonReentrant modifier from the OpenZeppelin ReentrancyGuard contract to prevent reentrancy attacks
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.