Admin creates new contest with organizer, contestId, closeTime and implementation. implementation is an contract address of distributor contract but can be passed as an EOA or address which don't have code, to create a contest
As explained in Summary an EOA address can be passed as implementation address which will emit an setContest
https://github.com/Cyfrin/2023-08-sparkn/blob/main/src/ProxyFactory.sol#L116
This event is an indicator to sponsors their interest of contest has been created and they will start investing by computing pre deployed address.
But all the delegate call to this implementation address will fail and funds will be locked in contract.
This problem arises majorly when Deployer deploy contract using CREATE2 opcode and doesn't do proper validation of contract deployed. So it will be best to do proper validation of implementation address
A eg Reference - https://solodit.xyz/issues/m-13-improper-validation-of-create2-return-value-code4rena-mochi-mochi-contest-git
https://github.com/Cyfrin/2023-08-sparkn/blob/main/src/Proxy.sol#L51C4-L64C6
Impact is critical as loss of all the funds sent to proxyContract but likelihood is not high so marking as medium
Manual
check for extcodesize(implementAddress) during setting a contest and revert if it is zero.
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.