Approval must be set to zero and after that increased to the amount you need. #5
Labels
bug
Something isn't working
duplicate
This issue or pull request already exists
QA (Quality Assurance)
Assets are not at risk. State handling, function incorrect as to spec, issues with clarity, syntax
Lines of code
https://github.com/code-423n4/2022-05-sturdy/blob/main/smart-contracts/ConvexCurveLPVault.sol#L141
https://github.com/code-423n4/2022-05-sturdy/blob/main/smart-contracts/ConvexCurveLPVault.sol#L146
https://github.com/code-423n4/2022-05-sturdy/blob/main/smart-contracts/LidoVault.sol#L102
https://github.com/code-423n4/2022-05-sturdy/blob/main/smart-contracts/YieldManager.sol#L221
Vulnerability details
Impact
Approval must be set to zero and after that increased to the amount you need.
Some of the tokens such as USDT require that.
Proof of Concept
Please read more information here: https://www.adrianhetman.com/unboxing-erc20-approve-issues/
Tools Used
Recommended Mitigation Steps
The text was updated successfully, but these errors were encountered: