Expected behaviour: Transfer the faucet token to the owner to ensure it has enough tokens to burn. Should transfer only the amount to burn.
Issue: Transfers all the balance from the contract rather than just the quantity necessary to burn. Then, it causes the contract to run out of funds.
Likelihood: High
Every time the burnFaucetTokens function is called, all the funds are transferred to the contract owner.
Impact: High
Owners may not be able to burn tokens twice when they burn fewer tokens than the contract's balance, and they do not mint tokens.
Users will not be able to claim tokens when owners burn fewer tokens than the contract's balance.
testOwnerBurnTwice tests when the owner burns an amount inferior to the INITIAL_SUPPLY_MINTED, but the contract should revert for insufficient balance
testUsersNotAbleToClaimAfterOwnerBurnTokens tests when a user claims tokens after an owner burns an amount inferior to the INITIAL_SUPPLY_MINTED, but the contract should revert for insufficient balance
Transfer the exact amount the owner wants to burn.
Use amountToBurn instead of balanceOf(address(this))
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.