Beginner FriendlyFoundryNFT
100 EXP
View results
Submission Details
Severity: medium
Valid

players array can grow too large

Summary

The players array can grow too large and thus become unusable.

Vulnerability Details

If the players array grows too large, new users will be prevented from participating as their call will run out of gas when checking for duplicates. This means that a malicious user can fill the array with their addresses and there will be a very high likelihood that they will end up the winner. If chances are greater than 50% and the economics make sense, they can prevent others from entering and thus gaming the raffle each time.

Impact

Medium

Tools Used

Foundry

Recommendations

Use mappings and uints to keep track of player status and participation rates.

Updates

Lead Judging Commences

Hamiltonite Lead Judge about 2 years ago
Submission Judgement Published
Validated
Assigned finding tags:

denial-of-service-in-enter-raffle

Support

FAQs

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

Give us feedback!