withdrawFees
FunctionThe withdrawFees
function attempts to transfer totalFees
amount without checking if the contract has sufficient USDC balance. This can lead to failed transactions when the tracked fees don't match the actual contract balance.
Likelihood:
Medium - Discrepancies between tracked fees and actual balance can occur due to failed transactions or external transfers
Low - The function is only called by the owner when fees are accumulated
Impact:
Transaction failures when attempting to withdraw more than the contract actually holds
Potential loss of fees if the contract balance is less than tracked totalFees
Explanation: This PoC demonstrates how the lack of balance validation can cause transaction failures when totalFees
doesn't match the actual contract balance.
Explanation: The fix adds balance validation before transfer to ensure the contract has sufficient USDC and prevent failed transactions.
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.