Liquidation may fail if PriceFeed.aggregator() is updated while Liquidataion pool uses hardcoded eurUsd pricefeed from the deployment
https://github.com/Cyfrin/2023-12-the-standard/blob/main/contracts/LiquidationPoolManager.sol#L23
LiquidationPoolManager deploys LiquidationPool and set the priceFeed _eurUSD
in a immuatable which cant changed in the future
https://github.com/Cyfrin/2023-12-the-standard/blob/main/contracts/LiquidationPool.sol#L18
https://github.com/Cyfrin/2023-12-the-standard/blob/main/contracts/LiquidationPool.sol#L34
while in the priceFeed contract, the address of aggregator can be changed by owner
https://etherscan.io/address/0xc7de7f4d4C9c991fF62a07D18b3E31e349833A18#code
Also chainLink documents says : you can call functions on the aggregator directly, but it is a best practice to use the AggregatorV3Interface to run functions on the proxy instead so that changes to the aggregator do not affect your application. Read the aggregator contract only if you need functions that are not available in the proxy.
https://docs.chain.link/data-feeds/price-feeds/api-reference#aggregatorv3interface
As this function is called internally during liquidation of smartVaults ,may prevent liquidation due to unavaibility/stale price of previous eurUSD
priceFeed
Manual
considering current implementation adding a setter with admin acess control could prevent this issue
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.