Christmas Dinner

First Flight #31
Beginner FriendlyFoundrySolidity
100 EXP
View results
Submission Details
Severity: high
Valid

Reentrancy flaw in the `refund()` function

Summary

Reentrancy flaw in the refund() function.

Vulnerability Details

-The refund() function uses the nonReentrant() modifier, but it's incorrectly implemented as the locked variable is set as false, failing to prevent reentrant calls.
-Due to this inaccurate implementation, the contract is vulnerable to potential reentrancy attacks.

Impact

-Critical security flaw that could allow an attacker to drain funds from the contract.
-Large financial losses could occur.

Tools Used

Static code analysis, Automated audit tools

Recommendations

Correct the implementation of nonReentrant() modifier ensuring that locked variable is set to true before the function call.
Adopt proper mitigation techniques against reentrancy attacks.

Updates

Lead Judging Commences

0xtimefliez Lead Judge 10 months ago
Submission Judgement Published
Validated
Assigned finding tags:

mutex lock incomplete

0xtimefliez Lead Judge 10 months ago
Submission Judgement Published
Validated
Assigned finding tags:

mutex lock incomplete

Support

FAQs

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