In the MisteryBox
contract, there is no verification to ensure that only the owner can function changeOwner()
.
Currently, anyone can change the owner
since there is no restriction on who can update the owner
variable.
This could result in the contract’s ownership being transferred unintentionally or maliciously, potentially locking the contract and making it inaccessible.
Manual review
Implement an onlyOwner
modifier and apply it to all functions that should be restricted to the contract owner:
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.