The burnFrom
function allows the festival contract to burn tokens from any address, at any time, for any amount, without the token holder’s approval. This bypasses the standard ERC20 allowance mechanism and exposes all users to the risk of having their tokens destroyed arbitrarily. If the festival contract is compromised or buggy, it can wipe out any user’s balance, leading to loss of funds and trust.
Likelihood:
The festival contract is a single point of trust; compromise or bugs in this contract will allow an attacker to burn tokens from any user.
No user approval or restriction exists, so a single malicious or erroneous call can destroy user funds.
Impact:
The attacker can burn all tokens from any user, resulting in direct loss of funds.
The protocol’s reputation and user trust are severely damaged.
The following code demonstrates how a malicious or compromised festival contract can burn all tokens from a victim, proving there is no restriction or approval required.
Require user approval (using the ERC20 allowance mechanism) before burning tokens from their account, or restrict burning so that only the token holder can burn their own tokens.
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.