Core Contracts

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

Naive Reward Distribution in StabilityPool

Summary:

The RAAC reward distribution in StabilityPool uses a simple pro-rata (userDeposit / totalDeposits) approach at withdrawal time. Early withdrawers can claim a large fraction of the total RAAC if the pool’s RAAC balance is high.

Vulnerability Details:

function calculateRaacRewards(address user) public view returns (uint256) {
return (raacToken.balanceOf(address(this)) * userDeposits[user]) / totalDeposits;
}

Participants who withdraw first may get a bigger portion of newly added RAAC.

Impact:

This leads to “first-withdrawer advantage” and a potentially unfair reward system, though it doesn’t strictly break the system.

Tools Used:

  • Manual review of distribution logic

  • Comparison with typical reward indexing

Recommendations:

  • Use a reward index approach, tracking each deposit’s entitlement over time.

  • Document the design if pro-rata is intentionally naive.

Updates

Lead Judging Commences

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

StabilityPool::calculateRaacRewards is vulnerable to just in time deposits

Support

FAQs

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