Description: The call to transfer tokens is not checked if it succeeded or failed.
Impact: The state variables are updated before calling this which is proper CEI.
If the call to transferFrom
fails then the contract would not revert, leading to incorrect balance tracking.
Recommended Mitigation: Check the return value of transferFrom
.
This same issue of not checking the result of transfer functions also occurs in TokenDivider::sellErc20
and TokenDivider::buyOrder
. In sellErc20
, it doesn't check the result of transferFrom
and in buyOrder
, it doesn't check the result of transfer
.
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.