In the deployment script, the USDC token address is needed twice:
as a parameter for the airdrop contract constructor
to fund the contract with the token
Instead of using the same variable for both actions, an unsafe use of inline address is done.
USDC address is declared on line 8:
Then, on line 18, the address is entered in plaintext instead of reusing the variable s_zkSyncUSDC
:
We must make sure that both addresses are identical for the protocol to work as intended. If they are different, the airdrop will fail, as the contract will try to send a token different that the one it holds.
As a consequence, tokens may get stuck into the contract and users won't be able to claim their airdrop.
Manual review
Reuse the variable:
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.