First, the digest variable used in deployProxyAndDistributeBySignature() function has not include the address(this) parameter and block.chainid parameter to limit the using scope of the signature only in this contract.
Second, attacker can call deployProxyAndDistributeBySignature() function multiple times with one signature. The signature can replay in this contract.
The digest variable is related with contestId and data, but not address(this) and block.chainid. It has not mark down these signature which have been used.
If there has orther project which using the same implementation scheme for signature, this signature can be replalyed from Sparkn
to other projects or from other projects to Sparkn
.
One signature can replay in this contract to call _distribute() multiple times.
Manual
Recommend to fix the ProxyFactory.deployProxyAndDistributeBySignature() function as follow.
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.