Core Contracts

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

Tokens blocked in RAACNft contract forever

Summary

In RaacNFT contract function mint() transfer from msg.sender tokens to contract balance, and there is no way to transfer them from contract.

Vulnerability Details

Function mint() at first, transfer tokens from user to contract balance, and after that, mint nft to user address.

function mint(uint256 _tokenId, uint256 _amount) public override { // @audit-think а как отсюдать выводить токены юзеру?
...
// transfer erc20 from user to contract - requires pre-approval from user
token.safeTransferFrom(msg.sender, address(this), _amount);
// mint tokenId to user
_safeMint(msg.sender, _tokenId);
...
emit NFTMinted(msg.sender, _tokenId, price);
}

Tokens can not been transfered to anywhere. Sponsor confirmed, that it is not designed choise.

Impact

Tokens will remain on the contract balance forever

Tools Used

Manual reveiw

Recommendations

Add function for remove tokens from contract.

Updates

Lead Judging Commences

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

RAACNFT collects payment for NFT minting but lacks withdrawal functionality, permanently locking all tokens in the contract

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

RAACNFT collects payment for NFT minting but lacks withdrawal functionality, permanently locking all tokens in the contract

Support

FAQs

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