collectFee() uses unsafe bare i_weth.transfer() — return value is not checkedThe collectFee() function calls i_weth.transfer(s_collector, collection) using the bare ERC20 transfer(). The bare .transfer() call does not check the return value. ERC20 tokens that return false on failure (instead of reverting) will silently fail, and the function will continue as if the transfer succeeded.
Likelihood:
Any WETH implementation that returns false on failure triggers silent loss.
The contract imported SafeERC20 (using SafeERC20 for IERC20) but the developer used the raw .transfer() instead.
Impact:
WETH fees can be silently lost — the transaction succeeds but the collector receives nothing. The WETH remains stuck in the contract.
Explanation: The vulnerability is architectural. The contract globally imports SafeERC20, but calls .transfer() directly. Since transfer() does not revert on a false boolean return, failed WETH transfers will execute silently.
Explanation: The mitigation simply changes .transfer to .safeTransfer so that the execution reverts immediately if the ERC20 token transfer fails.
The contest is live. Earn rewards by submitting a finding.
Submissions are being reviewed by our AI judge. Results will be available in a few minutes.
View all submissionsThe contest is complete and the rewards are being distributed.