Snowman Merkle Airdrop

AI First Flight #10
Beginner FriendlyFoundrySolidityNFT
EXP
View results
Submission Details
Impact: medium
Likelihood: medium
Invalid

M-2: claimSnowman unbounded mint loop — large snapshot balances can never be claimed

Root Cause

claimSnowman mints one NFT per loop iteration for amount = balanceOf(receiver) raw units via _safeMint. The merkle leaf binds (receiver, amount) exactly, so the balance cannot be split, yet a single claim for a large balance exceeds the block gas limit.

Description

Measured per-mint gas is ~33.9k. With a 30M block gas limit a single claimSnowman can mint at most ~800-900 NFTs. A user whose snapshot balance exceeds that: (a) cannot split across claims because the leaf requires the exact snapshot balance; (b) cannot mint all at once because it runs out of gas. Their airdrop is permanently unclaimable — there is no alternative path.

Risk (Impact / Likelihood)

Impact: Medium — permanent loss of airdrop entitlement (Snow ERC20 itself is unaffected and can be transferred). Likelihood: Medium — depends on snapshot distribution; Snow uses 18 decimals but counts raw units, so even modest economic holders can be affected.

Mitigation

Support batched claiming (nonce/claimed-count with updated leaf semantics), or mint proportionally instead of 1:1.

Updates

Lead Judging Commences

ai-first-flight-judge Lead Judge about 2 hours ago
Submission Judgement Published
Invalidated
Reason: Incorrect statement

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.

Give us feedback!