Skip to content

Recipient Share Lock During Dispute #498

Description

@Kingsman-99

Description

When a dispute is active, individual recipient shares should be lockable so a subset of recipients can still be paid while disputed shares remain frozen. This is more surgical than locking the entire invoice.

Technical Context

Add locked: bool to the RecipientShare struct in types.rs. Add lock_recipient_share(invoice_id, recipient: Address) and unlock_recipient_share admin-only methods to contracts/split/src/lib.rs. In release_payment, skip locked recipients and accumulate their shares in an UnreleasedFunds(invoice_id) storage key.

Acceptance Criteria

  • release_payment skips recipients whose locked flag is true
  • Locked share amounts accumulate under UnreleasedFunds(invoice_id)
  • unlock_recipient_share followed by a separate release_locked_funds call releases them
  • RecipientShareLocked and RecipientShareUnlocked events are emitted from events.rs
  • Locking a recipient not in the invoice returns RecipientNotFound
  • All CI checks (cargo build --target wasm32-unknown-unknown, cargo test, cargo clippy) pass and the branch has no merge conflicts

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programcomplexity: highComplex feature requiring deep knowledge - 200 ptssecuritySecurity hardening and access control

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions