Beginner FriendlyDeFiFoundry
100 EXP
View results
Submission Details
Severity: medium
Invalid

USDC `transfer` return value is ignored in `MoneyShelf::withdrawUSDC`, causing transfer status is unchecked

Description

The function MoneyShelf::withdrawUSDC ignores return value of usdc.transfer, so even if the transfer fails sliently (as long as it doesnt revert), it will still brun crimeMoney.

Impact

bank[to] might be changed, and crimeMoney might be burnt, even if no USDC is transferred out of MoneyShelf.

Recommendations

check the return value of usdc.transfer, if transfer fails, revert the tx

require(usdc.transfer(to, amount), "Token transfer failed");
Updates

Lead Judging Commences

n0kto Lead Judge about 1 year ago
Submission Judgement Published
Invalidated
Reason: Incorrect statement

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.