The tokenURI
function in the MondrianWallet smart contract does not adhere to the specified requirement of returning one of four random Mondrian art paintings with equal distribution.
ART_ONE
, ART_TWO
, and ART_THREE
are each returned only when the modulus operation results in 0, 1, and 2 respectively (each ~10% of the time), while ART_FOUR
is returned for the remaining 70% of tokens.
HIGH - The NFT associated with ART_FOUR will be the most common while ART_ONE
, ART_TWO
, and ART_THREE
will be equally scarce. As no rarity is assigned to each NFT. The impact is high, however, as no rarity is assigned to each NFTs there is minimal economic risk associated with this flaw in business logic.
Manual Review
Implement a secure method of generating random numbers within the smart contract to decide the art URI independently of the token ID. Consider using Chainlink VRF.
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.