Skip to content

Add transfer_with_attestation nonce and expiry to prevent attestation replay #561

Description

@greatest0fallt1me

Description

Attested transfers must include a nonce and an expiry timestamp so an attestation cannot be replayed. Nonces are per-signer and monotonically consumed.

Requirements and context

  • Must be secure, tested, and documented
  • Should be efficient and easy to review
  • Relevant code: src/test_transfer_with_attestation.rs
  • Consumed nonces persist to reject reuse

Suggested execution

  • Fork the repo and create a branch
  • git checkout -b feat/attestation-nonce-expiry
  • Implement changes
    • Extend attestation struct with nonce, expires_at
    • Persist consumed set keyed by (signer, nonce)
    • Reject expired or replayed attestations
  • Validate security and correctness assumptions

Test and commit

  • Run tests
    • cargo test --all
  • Cover edge cases
    • Attestation used at exact expiry second
  • Include test output and security notes

Example commit message

feat: add nonce and expiry to transfer attestations

Guidelines

  • Minimum 95 percent test coverage
  • Clear documentation
  • Timeframe: 96 hours

Activity

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

Metadata

Metadata

Assignees

Labels

Stellar WaveStellar Wave issue batch

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions