The Standard

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

SmartVaultV3::swap() deadline parameter is too low and could cause a swap to fail

Summary and Vulnerability Details

The deadline parameter in ExactInputSingleParams specifies the unix time after which a swap will fail. The currently provided value is block.timestamp, which could cause swaps to fail in production.

Impact

Swaps could fail on mainnet.

Tools Used

Manual Review

Recommendations

Ideally, this should be configurable by the user and an additional argument should be added to the swap() function. Otherwise, the following code can be used:

deadline: block.timestamp + 60
Updates

Lead Judging Commences

hrishibhat Lead Judge over 1 year ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity
Assigned finding tags:

deadline-check-low

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

deadline-check

Support

FAQs

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