The mintRamNFT
function in the RamNFT
contract lacks access control, allowing anyone to mint NFTs without cost, which could lead to abuse and unintended distribution of tokens.
RamNFT::mintRamNFT
function is used to mint Ram NFT, its called by Dussehra
contract where player must pay for minting. Problem is that this function does not have any access control, so anyone can just call this function directly and mint Ram NFT for free.
Player calls RamNFT::mintRamNFT
function 10 times.
Player has 10 tokens in his wallet.
Player didn't pay for minting tokens.
Place the following test into Dussehra.t.sol
.
Player can mint Ram NFT for free unlimited times which has strong financial impact on protocol, protocol is not getting money for minting tokens.
Also player can gain advantage by minting a lot of tokens, and then playing against others, maximizing his chance some of his token to be selected Ram.
Manual review
Add access control to RamNFT::mintRamNFT
function so only Dussehra
contract can call that function.
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.