Skip to content
Business logic Audit finding Advanced

createProposal snapshot block can temporarily desync with minApproval / minVotingPower

When a proposal is created, the contract records a snapshot block from one block earlier but uses the current approval threshold, so the set of eligible voters and the required approval can be out of sync. An attacker could exploit this to pass a proposal with fewer approvals than intended, potentially hijacking a multisig.

0x52 Follow with AkshaySrivastav

Originally disclosed on Code4rena

Submitted by 0x52, also found by AkshaySrivastav

minApproval and member list will be temporarily out of sync, potentially causing approval issues.

Proof of Concept

Multisig.sol#L214-L245

    uint64 snapshotBlock = block.number.toUint64() - 1;

    ...

    // Create the proposal
    Proposal storage proposal_ = proposals[proposalId];

    proposal_.parameters.snapshotBlock = snapshotBlock;
    proposal_.parameters.startDate = _startDate;
    proposal_.parameters.endDate = _endDate;
    proposal_.parameters.minApprovals = multisigSettings.minApprovals;

When creating a proposal all the voting contracts (multisig, token, addresslist) use a snapshot block that is one block in the past. The problem is that they use the current settings for determining min voting are but uses a snapshot block that is 1 block behind. This causes a desync between the members who can vote and the approval needed to pass a proposal.

Example Imagine the following scenario. There is a multisig with 10 members and a min approval of 6. There is some kind of leak that exposes the private keys of 4 of the members and their addresses are hijacked. The multisig creates a proposal that removes the 4 members and lowers the min approval to 4. On the block that the proposal is executed, one of the malicious members creates a proposal removing the other six members from the multisig. Now when that proposal is created it will use voting eligibility from the block before (which includes the 4 compromised accounts) but it will apply the newly changed min approval of 3. Now the 4 compromised accounts can approve their proposal and hijack the multisig.

Similar scenarios can occur in token and addresslist voting anytime the approval threshold and supply/members are changed in a single proposal.

Recommended Mitigation Steps

Threshold parameters should be snapshot the same way that eligibility or token balances are.

0xean (judge) decreased severity to Medium and commented:

Hard to see how this qualifies as High severity. The warden’s premise is built off of:

“There is some kind of leak that exposes the private keys of 4 of the members and their addresses are hijacked.”

Which by definition already means that there are security assumptions broken across the entire DAO. I think the point is however valid about the synchronization of these settings.

novaknole20 (Aragon) confirmed and commented:

Very good finding. Thank you


The original report as published on Code4rena, by 0x52. Images and videos are our own copies; raw HTML is shown as text. View it on Code4rena.

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 contract snapshots voter eligibility at a past block but reads the approval threshold from current settings, so changes to membership and threshold in the same block are not applied consistently.

Impact

An attacker could pass a proposal with fewer approvals than intended, potentially taking over a multisig, though the scenario requires compromised keys and the judge noted that this already breaks security assumptions.

What the attacker needed

Compromised member private keys; ability to create proposals; same-block proposal execution

The fix

Threshold parameters should be snapshotted in the same way as voter eligibility or token balances.

How it was found

  1. A multisig has 10 members and requires 6 approvals.
  2. Four members' private keys are compromised and their addresses are hijacked.
  3. The multisig creates and executes a proposal to remove the four members and lower the approval threshold to 4.
  4. In the same block, one of the malicious members creates a proposal to remove the other six members.
  5. That new proposal uses voter eligibility from the previous block (including the four compromised accounts) but applies the new lower threshold.
  6. The four compromised accounts approve the malicious proposal and hijack the multisig.

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.

A multisig is a wallet that needs several people to approve a transaction before it happens. This bug means that when a new vote is started, the list of who is allowed to vote comes from the previous block, but the number of votes needed comes from the current settings. If the settings changed in the same block, the two can mismatch, letting a smaller group than intended approve something.

What is Business logic?

The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.

More by 0x52

View all

211 more disclosed reports, best first.

More from Aragon Protocol contest

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Business logic flaws

The lesson behind this report.

The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.