Summary
Validation accepts both http:// and https://, so webhook payloads (with merchant_id, amounts, tx hashes) can be delivered in cleartext.
Location
src/api/payments.rs:130
- README API table states
webhook_url must be a "Valid HTTPS URL".
Details & impact
Cleartext webhook delivery exposes signed event bodies and headers to on-path attackers and contradicts the documented contract.
Suggested fix
Reject http:// on the public network (allow only for local/testnet dev, gated by config), and align the README/OpenAPI.
Acceptance criteria
http:// webhook URLs are rejected in production.
- Docs and code agree.
Summary
Validation accepts both
http://andhttps://, so webhook payloads (withmerchant_id, amounts, tx hashes) can be delivered in cleartext.Location
src/api/payments.rs:130webhook_urlmust be a "Valid HTTPS URL".Details & impact
Cleartext webhook delivery exposes signed event bodies and headers to on-path attackers and contradicts the documented contract.
Suggested fix
Reject
http://on thepublicnetwork (allow only for local/testnet dev, gated by config), and align the README/OpenAPI.Acceptance criteria
http://webhook URLs are rejected in production.