The loop inside the _white_list_collection
function will never break as it does not correctly iterate through the list. As a result, the contract owner cannot remove elements from the middle of the whitelist.
The loop is expected to break when the element is the last in the list or matches the target element, but the variable prev
is never updated to the next element. This causes an infinite loop.
Likelihood: High
This issue will always occur when the admin tries to remove an element from the whitelist, unless it is the first element in the list.
Impact: Low
The admin will not be able to directly remove a whitelisted collection from the list when necessary.
Manual Review
Likelyhood: High, owner can only unwhitelist the 2 first collections. Impact: Medium/High, owner has to empty the list to remove any collection, and replace all the new ones.
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.