Open code423n4 opened 3 years ago
s1m0
The token can be sent to address(0) through a normal transfer() without decreasing the totalSupply as it would with calling burn() and it could cause an unintentional burn.
https://github.com/code-423n4/2021-04-vader/blob/main/vader-protocol/contracts/Vader.sol#L122 https://github.com/code-423n4/2021-04-vader/blob/main/vader-protocol/contracts/USDV.sol#L102
Manual analysis
Consider checking the recipient address to be != address(0).
Handle
s1m0
Vulnerability details
Impact
The token can be sent to address(0) through a normal transfer() without decreasing the totalSupply as it would with calling burn() and it could cause an unintentional burn.
Proof of Concept
https://github.com/code-423n4/2021-04-vader/blob/main/vader-protocol/contracts/Vader.sol#L122 https://github.com/code-423n4/2021-04-vader/blob/main/vader-protocol/contracts/USDV.sol#L102
Tools Used
Manual analysis
Recommended Mitigation Steps
Consider checking the recipient address to be != address(0).