The vulnerability arises from the lack of validation for token addresses during registration, allowing the zero address to be registered as a collateral token. This can lead to high-severity issues, including transaction failures, denial of service, and operational disruptions, as functions attempting to interact with the zero address will revert.
The contract lacks proper validation when registering collateral tokens, allowing the zero address (0x0000000000000000000000000000000000000000) to be registered as a valid token. This oversight can lead to significant operational and security issues.
This will be the following impact if we oversight this issue.
addLiquidity:
Attempting to transfer a zero address token would fail, as the zero address is not a valid ERC20 token. This would likely cause the transaction to revert due to failed token transfer operations.
removeLiquidity:
Similar to addLiquidity, any operation involving transferring a zero address token would fail, leading to transaction reverts.
redeemPositionToken:
If the zero address is used as a position token, redemption operations would fail, as the contract cannot interact with a non-existent token contract.
redeemWToken:
Redemption involving a zero address wrapped token would fail for the same reasons, causing transaction reverts.
claimYield:
Yield claiming operations would fail if they involve transferring a zero address token, leading to transaction failures.
approveCollateralTokenForAave:
Attempting to approve a zero address token for Aave would fail, as the zero address cannot execute ERC20 functions like approve.
Manual Review
Add validation for zero address for resolving the issue.
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.