LibWstethEthOracle
has no minAnswer
implemented for getWstethEthPrice()
function.
getWstethEthPrice()
function uses getPrice()
function from the LibChainlinkOracle
.
LibChainlinkOracle#getPrice()
function doesn't have any minAnswer/maxAnswer
check.
Thus, during the extreme market events, there is no way to handle scenarios where the price of an asset falls outside of a predetermined price band
The Chainlink aggregator can lead to potential exploitation of price discrepancies during extreme market conditions. For instance, if the price of an asset experiences a sudden crash, the oracle may continue to provide the lower price, allowing users to conduct transactions at incorrect prices. This could result in financial losses for users and undermine the integrity of the system.
Also, when the peg loses tremendously like with the stETH/ETH peg not long after the LUNA crash. It was something like 8% loss in peg which meant you can buy stETH with a 8% discount against ETH. This situation can be prevented by adding minAnser/maxAnswer
bounds.
Manual Analysis
It is recommended to enhance LibWstethEthOracle
the by implementing a mechanism to check the returned answer against predefined minPrice
and maxPrice
bounds. If the answer falls outside of these bounds, the oracle should revert the transaction, indicating that the price data is not reliable due to market conditions.
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.