In Ditto.sol:16, there is no check to ensure that diamondAddr provided to the Ditto contract's constructor isn't the zero address. Given that the diamond address is used throughout the contract as a privileged entity (as seen in the onlyDiamond modifier), not verifying its integrity during the contract's initialization can lead to unforeseen consequences and potential misuse.
Manual Review
Before assigning the value of diamondAddr to the diamond state variable in the constructor, a check should be inserted to ensure that diamondAddr is not the zero address. If it is, the constructor should revert.
This can be achieved with a simple check:
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.