collateralLiqudationPriority
and activeMarketIds
are EnumerableSets
. During state modification, the values
function is called for both sets, which copies all set values to memory.
The issue arises if one of these sets grows large enough to cause a Denial of Service (DoS). The inline documentation for the values()
function states:
Additionally, both functions that use these set values perform numerous operations, increasing the likelihood of a DoS.
The protocol will become unusable as it will be impossible to remove a collateral priority from the list and liquidate some accounts.
Manual review
Implement a size limitation for both sets to prevent a DoS scenario.
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.