The LendingPool
contract allows the owner to modify the liquidation grace period after a liquidation has been initiated. This can lead to unexpected and unfair liquidations if the owner reduces the grace period, causing it to expire immediately for users who are already under liquidation.
In the LendingPool
contract, when a user is put under liquidation, they have a grace period to repay their debt and avoid liquidation. However, the owner has the ability to change this grace period at any time through the setParameter()
function:
The closeLiquidation()
function where the grace period check uses the current liquidationGracePeriod
value rather than the value that was in effect when the liquidation was initiated:
Unfair scenario:
User A gets liquidated with a 3-day grace period
After 2 days, the owner changes the grace period to 1 day
User A's grace period immediately expires even though they should have 1 more day to repay
The liquidation can be finalized immediately, resulting in an unfair liquidation
Users can unexpectedly lose their grace period due to owner actions
Manual Review
Store the grace period duration with the liquidation data when liquidation is initiated:
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.