Missing minted
value check while reducing the tier count may cause unexpected behaviours
External caller have an ability upgrade DAO tiers configurations using updateDAOMembership()
function. This function checks various parameters in order to validate the transaction is legit and execute it.
But in current version, it doesn't check the minted
values if the upgrade is reducing the count of the tiers.
Let say, we have 7 tiers in our DAO and external caller wants to reduce it to 6. In order to execute that transaction successfully, firstly we need to check whether there is a minted NFT on tier 7 because it will be gone after execution.
Our current implementation currently, update the minted
amounts for lower tier indexes and then it sets the new tier configuration to global state variables.
For safety, it should also check the high tier indexes. In realistic scenarios, external caller is trusted entity and he won't execute that kind of transaction but we still need to check that situation. Because it still can be happen without depending on the external caller ( such as re-org situation ).
Following test will simulate the scenario
Medium - It will break core functionality of the one world implementation. The users who have higher tier indexes can't upgrade their membership because noOfTiers
is updated after the configuration. Additionally, their NFT will hold invalid tier indexes.
Manual Review
Following check is needed for safety of execution.
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.