-
Notifications
You must be signed in to change notification settings - Fork 71
Open
Labels
Stellar WaveIssues in the Stellar wave programIssues in the Stellar wave programgood first issueGood for newcomersGood for newcomerssoroban-contract
Description
Allows token holders to be temporarily locked (e.g. during a voting window or vesting period), preventing token transfers.
Requirements
lock_tokens(env, asset_id, holder, until_timestamp) — Stores a lock record for the holder until the given ledger timestamp.
unlock_tokens(env, asset_id, holder) — Removes the lock record.
Transfer gate: In transfer_tokens, before executing, check if the from address has an active lock. If env.ledger().timestamp() < lock.until_timestamp, return Error::TokensLocked.
is_tokens_locked(env, asset_id, holder) — Read-only check.
Acceptance Criteria
- Locked tokens cannot be transferred
- Lock expires automatically when timestamp passes (checked in transfer)
-
unlock_tokensclears the lock regardless of timestamp
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Stellar WaveIssues in the Stellar wave programIssues in the Stellar wave programgood first issueGood for newcomersGood for newcomerssoroban-contract