Skip to content
DoS Audit finding Intermediate

Proposals can be cancelled

The DAO contract's cancelProposal function allows anyone to cancel any proposal by passing the same ID for both old and new proposal parameters, bypassing the minority check. An attacker could repeatedly cancel proposals, causing a denial of service that prevents governance actions.

Vader Protocol contest

Originally disclosed on Code4rena

Anyone can cancel any proposals by calling DAO.cancelProposal(id, id) with oldProposalID == newProposalID. This always passes the minority check as the proposal was approved.

An attacker can launch a denial of service attack on the DAO governance and prevent any proposals from being executed.

Recommend checking that oldProposalID == newProposalID

strictly-scarce (vader) confirmed:

This is valid, can fix with a require()

strictly-scarce (vader) commented:

The original report as published on Code4rena. 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

Likely the cancelProposal function does not verify that oldProposalID and newProposalID are different, allowing a caller to cancel a proposal by referencing it as both the old and new proposal.

Impact

An attacker could launch a denial of service attack on the DAO governance and prevent any proposals from being executed.

What the attacker needed

None

The fix

The fix should add a require statement to ensure oldProposalID and newProposalID are not equal.

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 smart contract is a program on a blockchain. This DAO contract lets people propose and vote on changes. The cancel function was supposed to let you cancel only your own new proposal if most voters disagreed with it. But because it didn't check that the two proposal IDs were different, anyone could cancel any proposal, even approved ones, and stop the DAO from working.

What is DoS?

A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.

More from Vader Protocol contest

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Denial of service

The lesson behind this report.

A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.