Distributor dynamically retrieves the currently set delegate from the centralized ProxyStorage contract. The target contract (delegate) is resolved inside the fallback function. It may return address(0). ProxyStorage does not enforce that the requested settings key exists, which may lead to Distributor delegate-calling into address(0), which returns no error. This might stay undetected when calling as the method does not return a value, which is consistent with calling a target address with no code.
https://github.com/Cyfrin/2023-08-sparkn/blob/main/src/Proxy.sol#L51-L63
Before delegate-calling into the target contract, check if it exists.
assembly {
codeSize := extcodesize(_target)
}
require(codeSize > 0);
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.