Description:
The initialize function assigns critical protocol dependencies without validating that the provided addresses are non-zero:
If any of these parameters is mistakenly set to address(0), the contract will be initialized with invalid dependencies.
Because this is an upgradeable contract using initializer, the function can only be executed once, making the misconfiguration permanent.
This is especially dangerous for:
aavePool
oneInchRouter
strataxOracle
as they are core to protocol execution and external calls.
Impact:
A wrong initialization can brick the contract or cause undefined behavior:
Calls to address(0) will revert, disabling core functionality (flash loans, swaps, oracle reads).
Funds could become stuck if operations depend on these integrations.
The contract cannot be reinitialized to fix the mistake.
Requires redeployment and migration, which is operationally risky and expensive.
This represents a configuration risk with permanent consequences, particularly relevant during deployment or upgrades.
Proof of Concept:
Deployment script mistakenly passes a zero address:
The contract is now locked with:
Any function relying on it will revert:
Since initializer prevents re-calling initialize, the contract cannot be repaired.
Recommended Mitigation:
Validate all critical inputs during initialization:
to avoid the use of magic numbers and improve clarity.
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.
The contest is complete and the rewards are being distributed.