Unbounded Loop:
If amount
is too large (e.g., 10,000+), the transaction will exceed block gas limits, reverting and wasting gas.
Impact: DoS for legitimate users; contract may become unusable.
Front-Runnable Token IDs:
s_TokenCounter
is incremented after minting, so a competing transaction could mint the same ID if included in the same block.
Impact: Duplicate token IDs or reverts due to ERC721's _safeMint
checks.
Lack of Access Control:
No onlyOwner
or role-based restriction; any address can mint unlimited tokens.
Impact: Inflation attack or spam.
Event Emission in Loop:
Emitting SnowmanMinted
for each iteration wastes gas.
Description: The function loops over amount
without a cap, allowing attackers to specify large values that exceed block gas limits.
Likelihood: Medium
Reason: Requires malicious intent but trivial to execute.
Impact: High
Effect: Permanent denial-of-service (contract becomes unusable for legitimate mints).
Description: s_TokenCounter
increments after minting, enabling parallel transactions to mint duplicate IDs in the same block.
Likelihood: High
Reason: Occurs naturally in high-activity networks (e.g., during NFT drops).
Impact: Critical
Effect: Breaks ERC721 uniqueness guarantee, leading to token loss/conflicts.
Description: Any address can mint unlimited tokens (no onlyOwner
or role restrictions).
Likelihood: High
Reason: Incentive for attackers to exploit (free tokens).
Impact: High
Effect: Inflation attacks, governance takeover, or spam.
Description: Emits SnowmanMinted
in a loop, wasting gas for batch mints.
Likelihood: Medium
Reason: Only affects users, not directly exploitable.
Impact: Low
Effect: Higher transaction costs, but no security risk.
Likelihood:
Reason: Requires malicious intent but trivial to execute
Reason: Only affects users, not directly exploitable
Reason: Incentive for attackers to exploit (free tokens).
Reason: Occurs naturally in high-activity networks (e.g., during NFT drops)
Impact:
Effect: Permanent denial-of-service (contract becomes unusable for legitimate mints).
Effect: Breaks ERC721 uniqueness guarantee, leading to token loss/conflicts.
Effect: Inflation attacks, governance takeover, or spam
Effect: Higher transaction costs, but no security risk.
The mint function of the Snowman contract is unprotected. Hence, anyone can call it and mint NFTs without necessarily partaking in the airdrop.
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.