Lack of slippage parameter makes Fees.sol
vulnerable to sandwich attacks which cause loss of funds.
Swap that executed in order to change fee tokens with WETH in order to send staking contract lacks slippage parameter as shown above. In swaps if amountOutMinimum
is 0, that tells Uniswap to return minimum 0 tokens. Because of this parameter, MEV bots can sandwich attack this swap call and by changing price of the token before and after swap; can steal funds from contract.
Important amount of fees collected will be stolen via sandwich attacks, hence protocol will lose funds, hence I consider this as high.
Manual Review
It is important to specify reasonble amountOutMinimum parameter. In order to do that, protocol can use price oracle to fetch price data; then use that data while calculating minimum amount of expected token.
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.