Platform: Code4rena
Start Date: 06/09/2022
Pot Size: $90,000 USDC
Total HM: 33
Participants: 168
Period: 9 days
Judge: GalloDaSballo
Total Solo HM: 10
Id: 157
League: ETH
Rank: 58/168
Findings: 2
Award: $222.38
🌟 Selected for report: 0
🚀 Solo Findings: 0
https://github.com/code-423n4/2022-09-nouns-builder/blob/7e9fddbbacdd7d7812e912a369cfd862ee67dc03/src/governance/governor/Governor.sol#L69 https://github.com/code-423n4/2022-09-nouns-builder/blob/7e9fddbbacdd7d7812e912a369cfd862ee67dc03/src/governance/governor/Governor.sol#L594
At this point in the Governer.sol contract #line594 it is possible to create and burn a vetoer, how ever, it would appear the ability to burn a vetoer and set the address of vetoer to 0 and leave the governance without a vetoer is possible, as no checks are carried out when burning said vetoer, there are also no checks at the start of setting up governance to ensure there is a vetoer either.
There is a 0 address check when storing governance setting for _treasury if (_treasury == address(0)) revert ADDRESS_ZERO(); and _token if (_token == address(0)) revert ADDRESS_ZERO(); , but you do not check to see if the there is a vetoer address, add into the "if" statements the following to mitigate.
// Ensure non-zero addresses are provided if (_vetoer == adress(0)) revert ADDRESS_ZERO();
Or simply combine the create and burn vetoer functions and create a 0 address check so that if a vetoer is burnt another is created so that governance is never left without one.
This could have a massive impact if onlyOwner was to burn a vetoer and then forget to create another, especially if an unsavoury character was to create some type of dangerous proposal, maybe one that drains funds or similar and there is no way of stopping the proposal from going through.
I still queston the Vetoe function within a DAO as handing power to one party mesans the DAO is no longer decentralised, how ever i do understand the need for one under theses circumstances.
(sidenote) Maybe the dev could find a way to write into the project a way of a vetoe vote, than can be cast by mulitple members, in order to keep the decentralised nature of a DAO, rather than giving power to a centralised agent for what ever reason is required.
@notice Updates the vetoer @param _newVetoer The new vetoer address function updateVetoer(address _newVetoer) external onlyOwner { if (_newVetoer == address(0)) revert ADDRESS_ZERO(); emit VetoerUpdated(settings.vetoer, _newVetoer); settings.vetoer = _newVetoer; } /// @notice Burns the vetoer function burnVetoer() external onlyOwner { emit VetoerUpdated(settings.vetoer, address(0)); delete settings.vetoer; }
#0 - GalloDaSballo
2022-09-20T19:13:29Z
Dup of #533
🌟 Selected for report: Lambda
Also found by: 0x1337, 0x1f8b, 0x4non, 0x85102, 0xA5DF, 0xNazgul, 0xSmartContract, 0xbepresent, 0xc0ffEE, 8olidity, Aymen0909, B2, Bnke0x0, CRYP70, Captainkay, CertoraInc, Ch_301, Chom, ChristianKuri, CodingNameKiki, Deivitto, Diana, DimitarDimitrov, ElKu, EthLedger, Franfran, Funen, GimelSec, JansenC, Jeiwan, Jujic, Lead_Belly, MEP, MasterCookie, MiloTruck, Noah3o6, PPrieditis, PaludoX0, Picodes, PwnPatrol, R2, Randyyy, RaymondFam, Respx, ReyAdmirado, Rolezn, Samatak, Tointer, Tomo, V_B, Waze, _Adam, __141345__, a12jmx, ak1, asutorufos, azephiar, ballx, bharg4v, bin2chen, bobirichman, brgltd, bulej93, c3phas, cccz, ch0bu, cloudjunky, cryptonue, cryptostellar5, cryptphi, csanuragjain, d3e4, datapunk, davidbrai, delfin454000, dharma09, dic0de, dipp, djxploit, eierina, erictee, fatherOfBlocks, gogo, hansfriese, hyh, imare, indijanc, izhuer, jonatascm, ladboy233, leosathya, lucacez, lukris02, m9800, martin, minhtrng, ne0n, neumo, oyc_109, p_crypt0, pashov, pauliax, pcarranzav, pedr02b2, peritoflores, pfapostol, rbserver, ret2basic, robee, rvierdiiev, sach1r0, sahar, scaraven, sikorico, simon135, slowmoses, sorrynotsorry, tnevler, tonisives, volky, yixxas, zkhorse, zzzitron
60.7775 USDC - $60.78
/// @param _duration The duration of each auction
There are no checks to see if the auction time has been set by some unreasonable character to unreasonable end time, or even by human error, maybe a check could be put in place to limit the max time of an auction to mitigate the posibility of this happening by accident or other wise.
mitigate by creating 1/3/7 day auction times as a standard
ALL files under "lib/interfaces/" source file (total 9 contracts), ALL files under "lib/proxy" (total 3 contracts), ALL files under "lib/token" (total 2 contracts), ALL files under "lib/utils/" (total 8 contracts)
#0 - GalloDaSballo
2022-09-27T00:39:21Z
No limits to maximum auction duration L
Fix pragma version before deployment to mainet R