The LendingPool::getNFTPrice()
function is intended to fetch the current price of an NFT from the oracle and check if the price is stale. However, the function does not implement the stale price check, as indicated in its comments. This omission can lead to inaccurate collateral valuation, causing protocol bad debts or unfair liquidations.
The getNFTPrice()
function retrieves the latest price and timestamp from the oracle but does not validate whether the price is stale (i.e., whether the lastUpdateTimestamp
is within an acceptable time window).
Overestimated Prices: If the price is stale and higher than the actual market value, users can borrow more assets than their collateral is worth, leading to protocol bad debts.
Underestimated Prices: If the price is stale and lower than the actual market value, users' health factors may fall below the liquidation threshold, causing unfair liquidations.
vscode
Add a stale price check to ensure the lastUpdateTimestamp is within an acceptable time window.
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.