Assessment reports>StaFi>Threat Models>withdrawWithPool

Function: withdrawWithPool(address _poolAddress)

Withdraw unstaked tokens from the pool.

Inputs

  • _poolAddress

    • Control: Full.

    • Constraints: None.

    • Impact: The bonded pool to withdraw unstaked tokens from.

Branches and code coverage (including function calls)

Intended branches

  • Calls withdrawForStaker.

Negative behavior

  • Cannot withdraw twice.

Function call analysis

  • IStakePool(_poolAddress).withdrawForStaker(erc20TokenAddress, msg.sender, totalWithdrawAmount)

    • What is controllable? Nothing.

    • If return value controllable, how is it used and how can it go wrong? Discarded.

    • What happens if it reverts, reenters, or does other unusual control flow? N/A.

Zellic © 2024Back to top ↑