Open code423n4 opened 1 year ago
0xSorryNotSorry marked the issue as primary issue
Fix PR here: https://github.com/nounsDAO/nouns-monorepo/pull/761
However, think severity should not be high. The worst case here is a signature abuse leads to a proposal going on chain, still subject to the proposal lifecycle, including quorum and voting.
eladmallel marked the issue as sponsor confirmed
eladmallel marked the issue as disagree with severity
Another point regarding severity: The signer can also move their tokens to another address as a way to make the previous signature not useful.
gzeon-c4 changed the severity to 2 (Med Risk)
Downgrading to Low since no asset will be at risk and require an user error.
gzeon-c4 marked the issue as satisfactory
gzeon-c4 changed the severity to QA (Quality Assurance)
gzeon-c4 marked the issue as grade-b
This previously downgraded issue has been upgraded by gzeon-c4
It is worth to note this is atypical in code4rena judging, and should not be considered as a precedence for future contests. Signature malleability, or outdated OZ dependency are generally considered as out-of-scope in c4 contests as they are covered by the bot report. This report is special in the sense that while the project already used the recommended OZ ECDSA library, the specific version they used contained a bug that allow malleability, which the warden provided a POC with meaningful impact. I am keeping this as Medium risk for the above reason and sponsor opinion.
gzeon-c4 marked the issue as selected for report
Lines of code
https://github.com/nounsDAO/nouns-monorepo/blob/718211e063d511eeda1084710f6a682955e80dcb/packages/nouns-contracts/contracts/governance/NounsDAOV3Proposals.sol#L270-L275 https://github.com/nounsDAO/nouns-monorepo/blob/718211e063d511eeda1084710f6a682955e80dcb/packages/nouns-contracts/contracts/governance/NounsDAOV3Proposals.sol#L983
Vulnerability details
Impact
The current version of openzeppelin contracts has a high risk of vulnerability about signature malleability attack: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/3610. So if the signer only cancel one signature, the malicious proposer can still extend a fully valid signature through the previous signature to pass the proposal.
Proof of Concept
Tools Used
Foundry
Recommended Mitigation Steps
Update openzeppelin contracts to the new version
Assessed type
Library