Liquid Staking

Stakelink
DeFiHardhatOracle
50,000 USDC
View results
Submission Details
Severity: medium
Invalid

Overshadowing of 'Strategy.canDeposit' by VaultControllerStrategy.sol

Summary
Overshadowing of 'canDeposit' by VaultControllerStrategy._depositToVaults().

Vulnerability Details
The state variables 'canDeposit' is declared in the Strategy contract and it is also redeclared in VaultControllerStrategy contract which inherits from the former.
https://github.com/Cyfrin/2024-09-stakelink/blob/f5824f9ad67058b24a2c08494e51ddd7efdbb90b/contracts/linkStaking/base/VaultControllerStrategy.sol#L197

Impact
The overshadowing of 'canDeposit' by VaultControllerStrategy.sol leads to the 'canDeposit' variable in its depositToVaults() function not functioning correctly thereby leading to unexpected outcomes.

Tools Used
Manual Review

Recommendations
Use a different variable name for the 'canDeposit' variable declared in depositToVaults() in VaultControllerStrategy contract.

Updates

Lead Judging Commences

inallhonesty Lead Judge 10 months ago
Submission Judgement Published
Invalidated
Reason: Lack of quality

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.