Core Contracts

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

Missing price validation controls in RAACNFT Minting

Vulnerability Details

The mint function in RAACNFT.sol lacks crucial price validation controls when fetching house prices from the oracle (raac_hp). The current implementation only checks if the price is non-zero and if the user has provided sufficient funds, but fails to implement:

  1. Price boundaries (min/max thresholds)

  2. Price deviation limits

  3. Circuit breakers for abnormal price movements

function mint(uint256 _tokenId, uint256 _amount) public override {
// @audit-issue missing min/max boundaries and price deviation limits
@> uint256 price = raac_hp.tokenToHousePrice(_tokenId);
@> if(price == 0) { revert RAACNFT__HousePrice(); }
@> if(price > _amount) { revert RAACNFT__InsufficientFundsMint(); }
...
}

As the house prices are defined off-chain, there must be a way to guarantee that when user is minting an NFT he won't pay an unfair price(otherwise it could lead the protocol or the user to lose funds).

As there is no check for price deviation limits, price boundaries(min/max) this is completely possible to happen.

ps: I submitted a separate report about the staled price, that's why it is not mentioned here.

Impact

  • Users can pay significantly more or less than the actual house value.

  • Protocols can suffer economic damage if the reported price is considerably low than the actual price.

  • System-wide economic imbalances if prices deviate significantly from market values

Tools Used

Manual Review

Recommendations

  1. Implement price boundaries(min/max).

  2. Implement price deviation limits.

  3. Allow governance to adjust the price boundaries and deviation limits.

  4. If possible, utilize multiple Oracle sources for price validation.

Updates

Lead Judging Commences

inallhonesty Lead Judge about 1 month ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity
inallhonesty Lead Judge about 1 month ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity

Support

FAQs

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