Core Contracts

Regnum Aurum Acquisition Corp
HardhatReal World AssetsNFT
77,280 USDC
View results
Submission Details
Severity: medium
Invalid

Proposal is defeated even in successful cases

Summary

Consider this scenario. Proposal is having forVotes > quorum() / 2, then it should be pass even with this currentQuorum < requiredQuorum condition. Its meaning, proposal has majority votes but due to not filling the requiredQuorum even with the againstVotes (it doesn’t matter who votes after next since majority is already voted for forVotes), proposal is considered to be defeated. But it should be success in that case. (In this case, it should fill the required vote gap with whatever vote for or against, due to not filling the required amount, vote is considered to be defeated).

Vulnerability Details

Here is the relavant code.

function state(uint256 proposalId) public view override returns (ProposalState) {
...
// Check if quorum is met and votes are in favor
if (currentQuorum < requiredQuorum || proposalVote.forVotes <= proposalVote.againstVotes) {
return ProposalState.Defeated;
}
...
}

Impact

Even when most voters support the proposal(forVotes > quorum() / 2), it can still fail due to insufficient total votes.

Tools Used

Manual Review

Recommendations

Add this code to to evaluate correctly.

if (currentQuorum < requiredQuorum && proposalVote.forVotes < (requiredQuorum / 2) || proposalVote.forVotes <= proposalVote.againstVotes) {
return ProposalState.Defeated;
}
Updates

Lead Judging Commences

inallhonesty Lead Judge 7 months ago
Submission Judgement Published
Invalidated
Reason: Incorrect statement
inallhonesty Lead Judge 7 months ago
Submission Judgement Published
Invalidated
Reason: Incorrect statement

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.

Give us feedback!