Core Contracts

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

Incorrect Documentation Claim: Batch Minting Not Implemented

Summary

The RAACNFT contract documentation claims that the contract supports batch minting, but the actual implementation does not provide any function for minting multiple NFTs in a single transaction. This discrepancy may mislead developers and users, causing incorrect expectations about the contract's functionality.

Vulnerability Details

  • The contract defines a currentBatchSize variable, which might suggest batch minting support.

  • The addNewBatch() function increases currentBatchSize, but it does not impact the minting process.

  • The only minting function available, mint(uint256 _tokenId, uint256 _amount), allows minting one NFT at a time.

  • There is no function that enables minting multiple NFTs in a single transaction.

  • The documentation states that "RAACNFT implements batch minting functionality," which is incorrect.

Impact

  • Misleading documentation may result in incorrect assumptions about contract capabilities.

  • Users or integrators expecting batch minting may face unexpected errors.

  • Developers may need to refactor or redeploy contracts if they assume batch minting is available.

Tools Used

Manuel Review

Recommendations

  • Fix the documentation to accurately describe that the contract only supports single NFT minting.

  • Implement a batch minting function if batch minting is required, such as:

    function batchMint(uint256[] memory tokenIds, uint256[] memory amounts) public {
    require(tokenIds.length == amounts.length, "Mismatched inputs");
    for (uint256 i = 0; i < tokenIds.length; i++) {
    mint(tokenIds[i], amounts[i]);
    }
    }
  • Verify contract behavior to ensure alignment with documentation.

Updates

Lead Judging Commences

inallhonesty Lead Judge about 2 months ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity
inallhonesty Lead Judge about 2 months ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity

Support

FAQs

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