Lack update of prev
may make bridge.cairo::_white_list_collection
stuck in dead loop and the whitelist won't be updated correctly.
In the bridge.cairo::_white_list_collection
removal branch loop, prev
isn't updated to next
.
When active
is true and next
is neither zero nor collection
, it gets stuck in dead loop. The removal will spend all gas and fail, and lead the upper level call to revert.
the linked list is like
Meanwhile, in a normal removal scenario, the whilelist won't be updated correctly also because the linked list isn't linked correctly.
Dead loop leads DoS
The whitelist can't get updated correctly
manual review
add prev=next
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.