Submitted by azephiar, also found by __141345__, bin2chen, cccz, davidbrai, pauliax, R2, rbserver, and Solimander
Its possible to create a proposal for a DAO as soon as its deployed and the proposal can pass even if nobody votes.
This possibility of doing so is based on the following assumptions:
The amount of time necessary to create and execute a proposal of this kind is dictated by governor.settings.votingDelay + governor.settings.votingDelay + treasury.delay(), the lower the time the higher the risk.
A malicious actor could build an off-chain script that tracks DAODeployed events on the Manager.sol contract. Every time a new DAO is spawned the script submits a proposal. This attack is based on the fact that such at an early stage nobody might notice and the chances of this happening are made real because every new DAO can be targeted.
A potential proposal created by an attacker might look like this:
With this setup the attacker can make a proposal and queue it immediately to then execute it after 1 day time; which gives him the time to veto any proposal that tries to interfere with the attack. At this point the attacker has sudo powers and if theres any bid he can take the funds.
This is just one possible attack path, but the point is making a proposal pass can give an attacker sudo powers and nobody might notice for a while.
Heres a test I wrote that proves the attack path outlined above, you can copy it into Gov.t.sol and execute it with forge test -m test_sneakProposalAttack:
This potential attack path comes from a combination of factors, maninly:
I would say that requiring at least 1 vote for a proposal to be considered Succeeded is rational and should mitigate this problem because that would require the attacker to bid on auction to get 1 voting power, increasing the cost and the time necessary for the attack.
At Governor.sol#L441 we have:
which can be changed to:
Alex the Entreprenerd (judge) commented:
Alex the Entreprenerd (judge) decreased severity to Medium and commented:
kulkarohan (Nouns Builder) confirmed
