This codebase is meant to be deployed on any EVM compatible chain. However, some chains such as Arbitrum and Optimism will open a possibility of stale trading without reverting
Chainlink on Arbitrum and Optimism have a sequencer uptime feed that allows project to check if an asset price is updated or is stale.
Currently, the OracleLib
allows a 3 hour threshold before marking a price result as stale.
Some feeds get updated very frequently and some do not, depends on price volatility. However 3 hours should indeed be enough.
HOWEVER - if a sequencer is down, price feeds will not be updated but can still be used on the L2.
Consider the following scenario.
Alice has 1000$
worth of ARB
token.
Alice sees that Arbitrum sequencer is down for 2 hours and the ARB
token price is down accordingly
To prevent loss of her token value, Alice deposits all her ARB
in the DSCEngine
. Since DSCEngine
does not check the sequencer feed, she will mint DSC
at a stale price worth of 1000$
.
Loss of funds (DCS incorrectly assumes prices)
Check the sequencer feed according to chainlink recommendations: https://docs.chain.link/data-feeds/l2-sequencer-feeds#overview
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.