Snow is an ERC20 with 18 decimals that can be bought with ETH or WETH before farming ends, and the fee is meant to be a price per token.
The constructor stores s_buyFee = _buyFee * 1e18 and buySnow charges s_buyFee * amount while it mints amount raw units, so one raw unit of Snow (1e-18 token) costs _buyFee whole ETH (5 ETH with the deployment fee of 5). Buying one whole token (1e18 units) would cost 5e36 wei, which nobody can pay, so the purchase path is effectively unusable and the price is wrong by a factor of 1e18.
Likelihood:
Affects every purchase, the formula is evaluated on every buySnow call.
The project tests only buy 1 raw unit for FEE = 5e18, which hides the problem.
Impact:
Buying Snow is economically impossible except for dust amounts, so the documented purchase path does not work.
Anyone who buys a tiny amount overpays by a factor of 1e18 compared with a per-token price.
The test uses the project deployment with fee 5. Buying 1 raw unit of Snow requires exactly 5 ETH. The test passes on the unmodified code.
Divide by PRECISION when computing the price, so that the fee is a price per whole token.
The contest is live. Earn rewards by submitting a finding.
Submissions are being reviewed by our AI judge. Results will be available in a few minutes.
View all submissionsThe contest is complete and the rewards are being distributed.