Core Contracts

Regnum Aurum Acquisition Corp
HardhatReal World AssetsNFT
77,280 USDC
View results
Submission Details
Severity: low
Valid

Parameter Order Mismatch in finalizeLiquidation() function

Vulnerability Details

The repayment process contains a critical mismatch between the DebtToken::burn() function return values and their handling in the LendingPool::finalizeLiquidation().

The return tuple order is inverted between scaled/unscaled amounts, leading to:

  1. Incorrect Asset Transfers

    Scaled amount (protocol's internal accounting units) used instead of actual asset amount

  2. Wrong Debt Balance Updates

    Scaled values treated as raw amounts, permanently corrupting user positions

  3. Protocol Insolvency Risk

    Mismatch between actual assets and accounting records

Impact

  1. Permanent loss of repaid funds

  2. Users unable to reduce actual debt

  3. Protocol accounting becomes unreliable

  4. Liquidation mechanisms break completely

  5. Protocol insolvency within hours of exploitation

Recommendations

Fix Return Value Handling

// correct order
(uint256 amountBurned, uint256 newTotalSupply, uint256 amountScaled, uint256 balanceIncrease) = burn(...)
Updates

Lead Judging Commences

inallhonesty Lead Judge 7 months ago
Submission Judgement Published
Validated
Assigned finding tags:

DebtToken::burn returns items in the wrong order

inallhonesty Lead Judge 7 months ago
Submission Judgement Published
Validated
Assigned finding tags:

DebtToken::burn returns items in the wrong order

Support

FAQs

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

Give us feedback!