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

DOS on withdrawal of fees

Summary

Withdraw fees function can be DOS'd.

Vulnerability Details

Function requires that the balance of the raffle == totalFees. If we send ETH to the contract, this check will always fail, leaving funds stuck in the contract.

An attacker could put the contract into this state by sending a very small amount of ether using self destruct.

Impact

Funds stuck in contract.

Tools Used

Manual review.

Recommendations

Create a function to recover ETH sent to the contract, or that amend function to allow full withdrawal after selectWinner called and before any new players enter.

Updates

Lead Judging Commences

Hamiltonite Lead Judge almost 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.