President Elector

First Flight #24
Beginner FriendlyFoundry
100 EXP
View results
Submission Details
Severity: low
Invalid

No validation of voter addresses

Summary

The constructor does not validate voter addresses.

Impact

//Inclusion of zero addresses may lead to unexpected behavior.
constructor(address[] memory voters) {
VOTERS = voters; // No validation
}

Tools Used

Manual Review

Recommendations

//Validate addresses during construction and input processing.
constructor(address[] memory voters) EIP712("RankedChoice", "1") {
for (uint256 i = 0; i < voters.length; i++) {
require(voters[i] != address(0), "Invalid voter address");
VOTERS.push(voters[i]);
}
}
Updates

Lead Judging Commences

inallhonesty Lead Judge 11 months ago
Submission Judgement Published
Invalidated
Reason: Lack of quality

Appeal created

0xethsol Submitter
11 months ago
inallhonesty Lead Judge
11 months ago
inallhonesty Lead Judge 11 months ago
Submission Judgement Published
Invalidated
Reason: Lack of quality

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.