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

Interest calculation error if L2 sequencer go down

Summary

Beedle Interest calculation depend on L2 sequencer, which will cause the interest calculation error if L2 sequencer go down.

Vulnerability Details

In the current implementation, some functions includes borrow, refinance and buyLoan, etc. depend on block.timestamp to calculate the interest and auction.startTimestamp.

However, it's vulnerable when l2 sequencer go down cause that block.timestamp is unuseable. L2 chains like arbitrum and optimism upgrade their sequencer occasional, such as the recent optimism bedrock upgrade cause the sequencer can't be able to process transactions for several hours. Or l2 sequencer bug could also cause transactions in stuck, such as arbitrum sequencer bug. So it's necessary to implement an mechanism to handle this issue in some abnormal conditions.

Impact

Some related functions will not work normal when l2 sequencer go down.

Tools Used

vscode, Manual Review

Recommendations

Use chainlink sequencer up feed, consider integrate the up time feed and give contract extra time when l2 sequencer go down.

Support

FAQs

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

Give us feedback!