Closed code423n4 closed 2 years ago
Dravee
As mistakes happen, address(0) checks should be made to avoid having to redeploy contracts
Here, the variable weth can't be updated after deployment: https://github.com/code-423n4/2022-01-timeswap/blob/5960e07d39f2b4a60cfabde1bd51f4b1e62e7e85/Timeswap/Timeswap-V1-Convenience/contracts/TimeswapConvenience.sol#L64
weth
VS Code
Add the address(0) check
Duplicate of #104
Handle
Dravee
Vulnerability details
Impact
As mistakes happen, address(0) checks should be made to avoid having to redeploy contracts
Proof of Concept
Here, the variable
weth
can't be updated after deployment: https://github.com/code-423n4/2022-01-timeswap/blob/5960e07d39f2b4a60cfabde1bd51f4b1e62e7e85/Timeswap/Timeswap-V1-Convenience/contracts/TimeswapConvenience.sol#L64Tools Used
VS Code
Recommended Mitigation Steps
Add the address(0) check