There is no tierconfigs.length in the structs
uint64 constant TIER_MAX = 7;
enum DAOType {
PUBLIC,
PRIVATE,
SPONSORED
}
struct DAOConfig {
string ensname;
DAOType daoType;
TierConfig[] tiers;
address currency;
uint256 maxMembers;
uint256 noOfTiers;
//joined members check
}
struct DAOInputConfig {
string ensname;
DAOType daoType;
address currency;
uint256 maxMembers;
uint256 noOfTiers;
}
struct TierConfig {
uint256 amount;
uint256 price;
uint256 power;
uint256 minted;
}
When creating a new DAO membership, there are a number of requirements for the creation to proceed. one of the require statement ensures if the nooftiers is equal to the configs length. The problem is that there is no tierconfigs.length. This means the check will not pass and the code will revert.
As can be seen in the structs above, there is no struct for tierconfigs.length. NewDAOMembership cannot be created.
Error in the require statements. This will lead to erroneous reverts
Manual Review
remove -
require(daoConfig.noOfTiers == tierConfigs.length, "Invalid tier input.");
or add add tierconfigs.length to the structs
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.