Normal Behavior: Users should be able to claim 1000 faucet tokens once every 3 days, with first-time users receiving 0.005 ETH additionally.
Vulnerability: The claimFaucetTokens() function violates the Checks-Effects-Interactions (CEI) pattern by making external calls before updating critical state variables. This allows malicious contracts to re-enter the function during ETH transfer and claim tokens multiple times in a single transaction.
Root Cause: External call to faucetClaimer.call{value: sepEthAmountToDrip}("") is made before updating lastClaimTime[faucetClaimer] and dailyClaimCount, allowing reentrancy attacks.
The claimFaucetTokens() function should allow users to claim exactly 1000 faucet tokens once every 3 days, with first-time claimers receiving an additional 0.005 ETH for gas purposes
The function enforces cooldown periods and daily claim limits to prevent abuse and ensure fair distribution of tokens.
Likelihood:
High: Any user can deploy a malicious contract and execute this attack
Easy to exploit: Requires basic Solidity knowledge and no special permissions
Impact:
Immediate fund drainage: Attackers can claim 2x-4x intended token amounts per transaction
Economic damage: Accelerated depletion of faucet reserves affects legitimate users
Trust violation: Core security assumption (one claim per cooldown) is broken
Attack: Attacker deploys malicious contract with receive() function 2. Calls startAttack() which triggers claimFaucetTokens() 3. During ETH transfer, receive() is called, triggering reentrancy 4. Second claimFaucetTokens() call succeeds because state isn't updated yet 5. Result: 2000 tokens inst
Test results: Expected: 1000 tokens, 1 daily claim - Actual: 2000 tokens, 2 daily claims - Proof: Attack succeeded with 100% fund increase per transaction
The fix implements Checks-Effects-Interactions pattern by moving all state updates before external calls. When reentrancy occurs, the cooldown check will fail because lastClaimTime is already updated, preventing multiple claims.
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.