Setting the default status as NICE could lead to potential issues as nonChecked users may bypass certain checks in the SantasList contract and mint NFTs.
The enum Status
uses NICE in the first position. However, in Solidity, each enum property is represented by a number under the hood. Additionally, all default values in the mappings s_theListCheckedOnce
and s_theListCheckedTwice
are set to 0. This means that all users are considered as NICE by default, granting them access to the collectPresent
function.
Non-checked users can mint NFTs regardless of their actual status.
Foundry
Consider using NAUGHTY as the default status to mitigate potential vulnerabilities.
In Solidity the first element of an enum is the default value. In Santa's List, the means each person is mapped by default to 'NICE'.
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.