No Cap on Amount of VOTES means the voter_admin can get any proposal to pass
The voter_admin can mint unlimited VOTES tokens because there is no cap on totalSupply, allowing them to manipulate governance outcomes by either vetoing or passing any proposal. An attacker with voter_admin privileges could mint enough tokens to meet or exceed the required thresholds.
Originally disclosed on Code4rena
Submitted by GalloDaSballo, also found by 0xNazgul, IllIllI, and rbserver
Because VOTES can be minted by voter_admin, and there is no cap on totalSupply, the voter_admin has the privileged ability to mint as many VOTES as they want in order to get any proposal to pass or veto it.
Proof of Concept - Veto
- Be
voter_admin - Mint XYZ tokens
- totalSupply is now higher so any proposal can be vetoed per this line
Proof of Concept - Approve
- Be
voter_admin - Mint XYZ tokens, where XYZ allows the
netVotes * 100 < VOTES.totalSupply() * EXECUTION_THRESHOLDcheck to pass - Mint
VOTESto self - Vote
- Proposal has passed
Recommended Mitigation Steps
Add a total supply cap to VOTES.
fullyallocated (Olympus) disputed and commented:
This is possible but will not happen in a production environment because we’re using this for internal testing.
Given the scope of the contracts the wardens were asked to review, I think this issue is valid. While I understand that the
voter_adminis trusted, I don’t think users expect the admin to be able to bypass any votes results in this manner.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
The VOTES token has no cap on totalSupply, and the voter_admin has minting privileges, allowing them to arbitrarily increase the supply and manipulate governance thresholds.
Impact
The voter_admin could bypass governance by minting unlimited VOTES to pass or veto any proposal, undermining the voting system.
What the attacker needed
Voter_admin privileges
The fix
Add a total supply cap to VOTES.
How it was found
- Be the voter_admin
- Mint XYZ VOTES tokens
- Mint VOTES to self
- Vote on a proposal
- Proposal passes or is vetoed depending on the action
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
In this system, a special admin can create new voting tokens without limit. Since voting power is based on how many tokens you have, this admin can create enough tokens to control any vote outcome, either by voting to pass a proposal or by increasing the total supply to make it harder for others to pass proposals. This breaks the intended fairness of the voting system.
What is Access control?
A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.