Assessment reports>Palmy Finance>Threat Model>depositFor

Function: depositFor(address _for, uint256 _value)

Deposits _value tokens for _for and adds to the lock.

Inputs

  • _for

    • Control: Controlled by the caller.

    • Constraints: Must be a valid address with an existing nonzero lock.

    • Impact: Specifies the address to deposit tokens for.

  • _value

    • Control: Controlled by the caller.

    • Constraints: Must be greater than zero.

    • Impact: Specifies the amount of tokens to deposit and add to the lock.

Branches and code coverage (including function calls)

Intended branches

  • Successful deposit and addition to an existing lock.

Negative behavior

  • Revert if no lock is associated with _for address.

  • Revert if _value is zero.

  • Revert if no existing lock is found for _lockerId.

  • Revert if the existing lock has expired.

Zellic © 2025Back to top ↑