Nested proxyAdmin for TransparentUpgradebleProxy will make the Proxy of DaoMembership contract unable to ugprade.
The DaoMembership is created by Factory contract through a TransparentUpgradeableProxy pattern. The transparent proxy mangage the admin role via the ProxyAdmin contract, which is created during the TransparentUpgradeableProxy constructor process. This will ease the procedure to upgrade implemention of the proxy. The ProxyAdmin::upgradeAndCall is supposed to call when upgrading the implementation, where in this call will be redirected to TransparentProxy. In such case, the admin of transparent proxy was set to be the AdminProxy. Howerver, the factory pass a already deployed proxyAdmin parameter to the TransparentUpgradeableProxy during createNewDAOMembership, which will lead the passed proxyAdmin as initalOwner to create another proxyAdmin. In this way the factory owner can never upgrade DAO proxy through the proxyAdmin created by owner in factory constructor process.
Essentially, this valnerability is caused by redundant proxyAdmin creating.
POC
add the following code to MembershipFactory.test.ts under descibre("MembershipFactory", function(){}):
DaoMemership contract will not be able to upgrade in future time.
Manual
consider remove the ProxyAdmin pattern generation during MembershipFactory constructing process.
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.