Skip to content

No numeric validation on payment amount fields (QuoteRequest.amount, SendPaymentRequest.send_amount) #17

Description

@abayomicornelius

src/models/payment.rs::QuoteRequest.amount and SendPaymentRequest.send_amount are plain Strings with no validation that they parse as a positive decimal number before being forwarded to Horizon's /paths/strict-send or used to build DB records.

A malformed or negative amount (e.g., \"-5\", \"abc\", empty string) will either produce a confusing downstream Horizon error or silently insert garbage into transactions.send_amount. Add explicit parsing/validation (positive, non-zero, correct decimal precision) in src/routes/payments.rs before calling into PaymentService.

Metadata

Metadata

Assignees

No one assigned

    Labels

    backendBackend service logicbugSomething isn't working

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions