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

Fees.sellProfits uses hardcoded fee of 3000

Summary

Fees.sellProfits uses hardcode fee of 3000, which can not fit to all pools and makes user to pay more fees for swap.

Vulnerability Details

Fees.sellProfits function is used to swap one token to weth. Currently, 3000 fee is provided to the router.
This is not correct, because there are different weth:token pools, that have different fee value, for example usdc:eth pool, that has 0.05 fee. User should be able to provide the most appropriate pool, that will provide better swap, but currently he can't.

Impact

Swap can't be done with the best pool

Tools Used

VsCode

Recommendations

Add ability for user to provide fee for the pool

Support

FAQs

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