The ERC20ToGenerateNftFraccion contract allows any address to mint unlimited tokens through an unprotected mint function. This critical vulnerability undermines the entire NFT fractionalization system.
In ERC20ToGenerateNftFraccion, the mint function lacks access controls:
An attacker can:
Call divideNft()
to legitimately divide their NFT into, say, 100 tokens.
Directly call mint()
to create any additional amount of tokens.
Trade these tokens using regular ERC20 transfers.
Keep enough tokens to claim back the NFT through claimNft()
.
While TokenDivider
includes protected trading functions (sellOrder
and buyOrder
), these don't prevent the exploit because malicious trading can occur entirely through standard ERC20 transfers, completely bypassing the TokenDivider contract.
This vulnerability allows attackers to:
Create unlimited unauthorized NFT fractions.
Sell these fractions to unsuspecting buyers.
Maintain enough tokens to reclaim the original NFT.
Profit while retaining control of the underlying NFT.
Manual review
Add access control to the ERC20ToGenerateNftFraccion contract:
Update TokenDivider
's divideNft
function to pass its address:
Any person can mint the ERC20 token generated in representation of the NFT
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.