A re-entrancy vulnerability in refund() can allow the attacker to drain all funds.
refund() is sending native ether to the account msg.sender which will trigger a callback if the msg.sender account is a smart contract. Because the state variable players is not cleared for playerIndex before the callback is triggered, an attacker can re-enter refund() and have it send more native ether to msg.sender.
This will result in all the funds being drained out of the contract.
Manual review
Make the state changes before sending ether or use non-reentrant libraries or locks/mutexes.
reentrancy in refund() function
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.