The _authorizeUpgrade
function is vulnerable to manipulation by blackhat aggressors, and gives them control over the contract.
This function is needed for proper UUPS implementation:
However, it is callable by anyone. Therefore, an attacker can call this function to unlawfully create a new implementation.
Here is a PoC:
an attacker wants to take over the wallet
the attacker passes a new address to the _authorizeUpgrade
function
the contract is successfully upgraded to the new address
the attacker is in charge!
Possible hijack of the wallet control.
Manual review.
Make the function only callable by the admin.
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.