The protocol creates a contest by assigning each player a reward during Pot deployment.
The issue is that no validation ensures players.length == rewards.length, causing mismatched indexing and inconsistent reward assignment.
Likelihood:
Contest configurations are manually provided during creation, making input mistakes realistic.
The contract accepts inconsistent array lengths without validation, allowing invalid states to be deployed.
Impact:
Some players may not receive rewards or may receive unintended values.
Reward distribution becomes inconsistent with the intended configuration, leading to incorrect or incomplete payouts.
A contest is created with fewer players than rewards:
players.length = 2
rewards.length = 3
During construction:
The extra reward (300 ether) is never assigned to any player, resulting in an inconsistent state where part of the rewards has no valid recipient.
Validate input lengths before deploying the Pot.
This keeps the system invariant:
The contest is live. Earn rewards by submitting a finding.
Submissions are being reviewed by our AI judge. Results will be available in a few minutes.
View all submissionsThe contest is complete and the rewards are being distributed.