The Standard

The Standard
DeFiHardhat
20,000 USDC
View results
Submission Details
Severity: low
Invalid

The ``distributeAssets()`` of LiquidationPool.sol contract may revert due to out of gas error.

Summary

The distributeAssets() of LiquidationPool.sol contract may revert due to out of gas error.

Vulnerability Details

There is a unique holder per position which is added when pendingStakes are consolidated here. The issues lies if there are too many positions open at once which resutls in too many holders. Then the distributeAssets() of LiquidationPool.sol has to iterate through all the holders one by one and in doing so, The transcation cost may exceed the block gas limit.

Impact

The rewards can never be added and runLiquidation of LiquidationPoolManager.sol will revert if distributeAssets() of LiquidationPool.sol reverts.

Tools Used

Manual Review

Recommendations

Add a limit on number of positions that can be opened or be active at once which will limit number of unique holders.

Updates

Lead Judging Commences

hrishibhat Lead Judge over 1 year ago
Submission Judgement Published
Invalidated
Reason: Known issue
Assigned finding tags:

informational/invalid

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.