Skip to content

Invoice ratings vector limits and abuse prevention #721

@Baskarayelu

Description

@Baskarayelu

Description

Cap ratings count, validate score bounds, and prevent unbounded storage growth.

Requirements and context

  • Must be secure, tested, and documented
  • Should be efficient and easy to review
  • Align with existing Soroban contract patterns in quicklendx-contracts

Suggested execution

  • Fork the repo and create a branch
  • git checkout -b feature/invoice-ratings-limits
  • Implement changes
  • Write contract: src/invoice.rs
  • Write comprehensive tests: src/test_invoice.rs, src/test_string_limits.rs
  • Add documentation: docs/contracts/invoice.md
  • Include NatSpec-style comments (Rust doc comments on public items)
  • Validate security assumptions

Test and commit

  • Run tests
  • Cover edge cases
  • Include test output and security notes

Example commit message

feat: add invoice ratings limits and validation

Guidelines

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Stellar WaveIssues in the Stellar wave programinvoiceAuto label for contract issues: invoicepriority-mediumAuto label for contract issues: priority-mediumsmart-contractsAuto label for contract issues: smart-contractstestingAuto label for contract issues: testingvalidationAuto label for contract issues: validation

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions