The BeatToken contract should only allow the contract owner to mint new tokens and burn existing tokens from any address. This ensures that the token supply is controlled by a trusted party (the owner) who can be held accountable and can implement emergency measures if needed.
The festivalContract should have limited permissions (e.g., only minting rewards up to a certain limit) or should work alongside the owner, not replace the owner's authority entirely.
The mint() and burnFrom() functions lack the onlyOwner modifier and instead rely solely on a check against the festivalContract address. This creates a critical access control vulnerability because:
Once festivalContract is set (and it can only be set once), that contract gains absolute and unlimited power to mint and burn tokens
The owner has no way to revoke, override, or stop the festival contract if it becomes malicious or gets hacked
The owner themselves cannot mint or burn tokens - only the festival contract can
There is no emergency stop mechanism or fallback
| Factor | Assessment |
|---|---|
| Compromised festival contract | Very High - Smart contract hacks are common |
| Social engineering attack | Medium - Owner could be tricked into setting malicious address |
| Owner key compromise | Low-Medium - Depends on security practices |
| Time to exploit once compromised | < 1 minute - Attack is trivial to execute |
| Impact Area | Severity | Description |
|---|---|---|
| Token Supply | CRITICAL | Unlimited minting - supply becomes infinite |
| User Funds | CRITICAL | Anyone's tokens can be burned without consent |
| Token Value | CRITICAL | Price crashes to zero immediately |
| Protocol Trust | CRITICAL | Complete loss of user trust |
| Exchange Status | CRITICAL | Token would be delisted immediately |
| Recovery | IMPOSSIBLE | No mechanism to reverse or stop the attack |
Scenario 1: Hacked Festival Contract
Scenario 2: Malicious Contract Setup
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.