Description:
In redeemMemorabilia
, the check
is off by one. Since currentItemId
starts at 1, a collection with maxSupply = N
only ever mints N−1 items—and if maxSupply = 1
it mints 0 items.
Impact:
Organizers and collectors cannot mint the full intended supply. In the worst case (maxSupply = 1
), no memorabilia can ever be redeemed.
Proof of Concept: Add the following test to the 'FestivalPass.t.sol' file:
Mitigation:
Change the supply check to allow exactly maxSupply
items, e.g.:
— or better, start currentItemId
at 0 and use < maxSupply
, then increment after mint.
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.