Skip to content

Add stale audit grant pruning behavior #356

Description

@edehvictor

Summary

Add behavior for pruning expired audit grants without affecting active grants or historical audit references.

Why This Matters

Expired grants should not keep granting visibility, but pruning must not destroy evidence needed for later verification.

Suggested Files

  • contracts/src/audit.rs
  • contracts/src/storage.rs
  • contracts/src/events.rs
  • contracts/tests/audit_grant_pruning.rs

Tasks

  • Identify expired audit grants by expiry timestamp.
  • Add idempotent pruning for stale grants.
  • Preserve digest references needed for audit history.
  • Emit safe pruning events.

Acceptance Criteria

  • Expired grants no longer authorize access.
  • Active grants are not pruned.
  • Historical digest references remain intact.
  • Tests cover expired, active, and already-pruned grants.

Coordination

Join the Telegram channel for proper coordination: https://t.me/zkpayroll

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Stellar WaveIssues in the Stellar wave program

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions