The mintRapper function in OneShot.sol improperly initialises OneShot::rapperStats before any gameplay, granting newly minted NFTs unearned skill advantages, which undermines the intended game mechanics.
The default values of OneShot::rapperStats for a newly minted NFT are beneficial to the player (weakKnees: false, heavyArms: false, spaghettiSweater: false, calmAndReady: false, battlesWon: 0). Score +15 already.
A malicious player could take control when he receives a NFT with a custom implementation of onERC721Received. He will then reenter on RapBattle::goOnStageOrBattle.
It gives an unfair advantage to players who mint new NFTs. Nevertheless the game is also based on chance in the end.
Manual Review
Restructure the OneShot::mintRapper to follow the Checks-Effects-Interactions pattern strictly. Ensure all state changes are performed before any extenal interaction.
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.