The key issue is that locked = false is not set to true before the function execution (_). This means that when the actual function executes at _;, the lock is still false. This completely defeats the purpose of the reentrancy guard, as the lock state isn't maintained accurately during function execution.
Could lead to reentrancy which leads to loss of ether in the contract when a user who registered using eth calls for refund within the deadline duration
foundry
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.