Because BeatToken is also Ownable2Step and Ownable from the OpenZeppelin contracts, any owner can call the function renounceOwnership()
and set the contract owner's address to address(0)
.
The function renounceOwnership()
is inherited via openzeppelin-contracts/contracts/access/Ownable.sol
it is true that it can only be executed by the owner at the moment, but if someone executes it, then it will render the BeatToken unavailable.
Likelihood:
The current owner of the BeatToken is disgrunted and decides to renounce on the ownership
The owner private keys are compromised and the attacker issues the renounceOwnership()
function to do a DoS
Impact:
After the execution of renounceOwnership()
it is not possible to transfer to a new owner
After the execution of renounceOwnership()
it is not possible to set any festival contract
Seems when it happens no operations required by the owner are possible, including withdraw.
Add the entry beatToken.renounceOwnership(); at any point of any test, even just after the creation of the token
In src/BeatToken.sol
add the following function, I recommend to add it at the end of the code for ease of read.
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.