The Standard

The Standard
DeFiHardhat
20,000 USDC
View results
Submission Details
Severity: medium
Invalid

Users with a high reserve ratio will be at risk of losing slippage protection when performing swap operations.

Summary

Users with a high reserve ratio do not have slippage protection when calling the SmartVaultV3.swap function, which will cause losses.

Vulnerability Details

When executing the SmartVaultV3.swap function, if collateralValueMinusSwapValue >= requiredCollateralValue is satisfied (which represents the user's collateral value > minimum collateral value + swap amount), the amountOutMinimum of the swap operation will be set to 0, that is, slippage protection will not be performed.

##Impact
This operation will cause users with a high reserve ratio to suffer from the risk of losing slippage protection when performing swap operations, suffering losses due to currency price fluctuations, or sandwich attacks.

Tools Used

Recommendations

Suggestion: Add an input parameter minOut in the swap function. On the premise of meeting the minimum reserve ratio, let users set amountOutMinimum themselves.

Updates

Lead Judging Commences

hrishibhat Lead Judge over 1 year ago
Submission Judgement Published
Validated
Assigned finding tags:

Slippage-issue

hrishibhat Lead Judge over 1 year ago
Submission Judgement Published
Invalidated
Reason: Known issue
Assigned finding tags:

Slippage-issue

Support

FAQs

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