The reinitializer version set in OperatorVCS.sol corresponds to its previous implementation which will cause the initialization of the new contract to fail.
OperatorVCS.sol is an upgrade of the previous contract of the same name. Which is why its initialize uses the reinitializer modifier. However, the version set in the reinitializer is the same as the previous version.
For comaprison, here's our current implementation
And here's the previous:
As can be seen, some extra features have been added in the spirit of its upgradeability.
However, the same reinitilizer version 3 is used, both by the current and the previous.
Looking at OpenZeppelin's reinitilizer modifier in Initializable.sol
First, we learn that a version number cannot be reused.
The initialization functions use a version number. Once a version number is used, it is consumed and cannot be
reused. This mechanism prevents re-execution of each "step" but allows the creation of new initialization steps in
case an upgrade adds a module that needs to be initialized.
And further, we look at the modifier, we can see that it requires that the _initialized parameter is less than the entered version before it sets the version to the _initialized parameter.
As seen in the previous contract implementation, reinitializer(3) was used, meaning that the _initialized parameter is now 3.
So, attempts to reinitialize the contract will always fail due to the required _initialized < version check in the reinitializer modifier.
For an extra bit of context, we can see from our search here that OperatorVCS has been deployed 3 times.
First on Jan 11, 2023, deployed with the normal initializer modifier which is the equivalent of setting _initialized to 1
Next on Nov 28, 2023, deployed with reinitilizer(2) which sets our _initialized to 2.
Finally on Dec 6, 2023, deployed with reinitializer(3) which sets our _initialized to 3.
As a result, using reinitializer(3) in current OperatorVCS will cause intialization to always fail, and as such, contracts will be unusable.
OperatorVCS will be uninitializable making it more or less unusable
Manual Review
Upgrade the version > 3.
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.