20,000 USDC
View results
Submission Details
Severity: high
Valid

`sellProfits` should provide a slippage protection

Summary

swap operation lost of slippage protection

Vulnerability Details

amountOutMinimum can't set to zeo in production. This value should be calculated using uniswap SDK or an onchain price oracle - this helps protect against getting an unusually bad price for a trade due to a front running sandwich or another type of price manipulation

sqrtPriceLimitX96 can't set to zero in production.This value can be used to set the limit for the price the swap will push the pool to, which can help protect against price impact or for setting up logic in a variety of price-relevant mechanisms.

Impact

under attack like sandwich.

Tools Used

manual

Recommendations

use uniswap SDK calculate amountOutMinimum and sqrtPriceLimitX96 before swapping.

Support

FAQs

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

Give us feedback!