The AaveDIVAWrapper::registerCollateralToken contract enables the registration of _collateralToken. When a token is registered via the _registerCollateralToken function, a mapping is updated to link the collateral token to its corresponding wToken. The registerCollateralToken function includes a validation check to ensure that the _collateralToken is supported by Aave V3 at the time of registration. If this check passes, the token is considered supported and can be used within the aaveDIVAWrapper.
However, an issue arises if a previously registered _collateralToken later becomes unsupported by Aave V3. The aaveDIVAWrapper contract does not provide a function to unregister collateral tokens, meaning users can still retrieve it as a registered token via getWToken. Consequently, they may attempt to call createContingentPool, using this _collateralToken, which will revert due to the token no longer being supported by Aave.
If _collateralToken is registered in the aaveDIVAProtocol but later becomes unsupported by Aave V3, users attempting to create pools, using this _collateralToken, via createContingentPool will experience continuous reverts.
Manual review.
Implement anAaveDIVAWrapper::unregisterCollateralToken function (with onlyOwner access) for unregistering _collateralToken that are no longer supported.
This is invalid. If the collateral token is not supported by Aave or invalid, the `registerCollateralToken` will revert. If the collateral token is deprecated by Aave due to a given issue, this is known issue: "Integration risk with both Aave V3 and DIVA Protocol - vulnerabilities in either protocol may affect AaveDIVAWrapper."
This is invalid. If the collateral token is not supported by Aave or invalid, the `registerCollateralToken` will revert. If the collateral token is deprecated by Aave due to a given issue, this is known issue: "Integration risk with both Aave V3 and DIVA Protocol - vulnerabilities in either protocol may affect AaveDIVAWrapper."
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.