Liquid Staking

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

deployments/mainnet.json

Potential Vulnerabilities and Risks:

1. ERC20 and ERC677 Contracts (Tokens)

  • Contracts: LPLToken, LINKToken, METISToken, stETHToken, cbETHToken, etc.

  • Risks:

    • Re-entrancy attack during token transfers or approvals (if transferAndCall in ERC677 isn't well-handled).

    • Approval double-spend vulnerability: If the old approval isn’t set to 0 before updating, this could be exploited.

    • Infinite minting risks: Ensure no unauthorized entity can mint tokens beyond the cap (if applicable).

    Recommendation: Review for re-entrancy protection (use of checks-effects-interactions pattern and reentrancy guards) and safe approval logic.


2. Vesting Contracts (SDL_Vesting_NOPx)

  • Contracts: SDL_Vesting_NOP0 to SDL_Vesting_NOP13, SDL_Vesting_LinkPool.

  • Risks:

    • Incorrect vesting logic: Flawed release schedules can lock or unlock tokens incorrectly.

    • Privilege escalation: Ensure only authorized accounts (e.g., admins) control vesting parameters.

    • Misconfiguration risks: Over-reliance on admin-controlled configurations could result in abuse.

    Recommendation: Ensure the contract follows principle of least privilege. Verify the vesting logic to prevent premature or locked token releases.


3. Staking and Reward Pools

  • Contracts: LINK_StakingPool, METIS_StakingPool, stLINK_SDLRewardsPool.

  • Risks:

    • Staking amount overflow: Use SafeMath to prevent overflow in staking balances.

    • Slashing or withdrawal logic errors: Errors in withdrawing rewards or tokens can lead to fund loss.

    • Reward distribution flaws: Malicious users might drain rewards if the calculation is faulty (e.g., time-weighted rewards).

    Recommendation: Verify reward calculation formulas. Confirm that the pool state transitions correctly during staking and unstaking.


4. Wrapped Tokens and Token Bridges

  • Contracts: LINK_WrappedSDToken, stLINK_WrappedTokenBridge, ixETH_WrappedSDToken.

  • Risks:

    • Bridge exploits: Bridges are prone to attacks, especially if they rely on off-chain oracles or are not audited well.

    • Wrapped token inconsistencies: Ensure the correct 1:1 peg with the underlying asset.

    Recommendation: Validate oracle inputs for bridge contracts and perform rigorous testing of wrapping/unwrapping logic.


5. Routers, Adapters, and Controllers

  • Contracts: PoolRouter, ixETH_LidoLSDIndexAdapter, ixETH_CoinbaseLSDIndexAdapter, LinearBoostController.

  • Risks:

    • Access control vulnerabilities: Routers may allow unauthorized swaps if not protected properly.

    • Misrouting risks: A poorly designed router can cause token mismanagement or front-running attacks.

    • Logic errors in adapters: Adapter functions must accurately interact with external protocols; otherwise, users can lose funds.

    Recommendation: Confirm role-based access controls (RBAC) on critical functions and use MEV protection techniques (like time-locking swaps).


6. Oracle-based Contracts

  • Contracts: LINK_PP_DistributionOracle, METIS_PP_DistributionOracle.

  • Risks:

    • Oracle manipulation: A compromised oracle could distribute incorrect rewards.

    • Price or data feeds: Delayed or inaccurate data can be exploited for arbitrage or reward draining.

    Recommendation: Use trusted or decentralized oracles and implement upper/lower bounds on input values.


7. Migration and Fee Contracts

  • Contracts: LPLMigration, FlatFee.

  • Risks:

    • Token migration risks: Migration processes could lock funds if not executed correctly.

    • Fee skimming or draining: Ensure the fee logic does not allow malicious users to avoid fees.

    Recommendation: Audit migration logic to ensure tokens cannot get stuck. Verify that fee settings cannot be altered maliciously.


General Recommendations:

  1. Audits: Ensure all smart contracts have undergone third-party security audits.

  2. Upgradability Risks: If any contracts are proxy-based, confirm no malicious upgrades can occur.

  3. Access Controls: Ensure admin roles are well-restricted and no single point of failure exists (e.g., use multisig wallets for critical functions).

  4. MEV Protections: Check if front-running or sandwich attacks are possible in routers or pools.


Updates

Lead Judging Commences

inallhonesty Lead Judge about 1 year ago
Submission Judgement Published
Invalidated
Reason: Lack of quality

Support

FAQs

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