Skip to content

EscrowController.splitRelease returns raw Payment[] entities, bypassing the toPublicEscrow response shaping every other escrow endpoint uses #91

Closed

Description

@chonilius

src/escrow/escrow.controller.ts's fund, findOne, release, and refund handlers all wrap their result in toPublicEscrow(...) (src/escrow/escrow-response.mapper.ts), which exists specifically to strip Escrow.metadata — internal Soroban diagnostic detail, including raw error messages — before it reaches an HTTP client (per the mapper's own doc comment, referencing #19).

splitRelease is the one exception: return this.escrowService.splitRelease(id, dto.recipients); returns the raw Payment[] array straight from the ORM with no mapping step at all. Payment doesn't currently carry anything as sensitive as Escrow.metadata, so this isn't an active data leak today, but it's an inconsistency in the same controller that the rest of the file was explicitly fixed to avoid — any field later added to Payment for internal bookkeeping (a Soroban metadata-style column, say) would leak by default on this one endpoint with nothing to catch it in review.

Fix: introduce a toPublicPayment/toPublicPayments mapper (even a thin passthrough today) and route splitRelease's response through it, matching the pattern already established for Escrow.

Activity

  1. added
    bug
    good first issue
    architecture
    security
    documentation
    on Aug 21, 2026
  2. added
    Stellar Wave
    on Aug 25, 2026
  3. Adewumi99 commented on Aug 25, 2026

    @Adewumi99

    @Adewumi99 has applied to work on this issue as part of the Stellar Wave Program's 8th wave.

    "Hi, I'd really like to contribute to this project by taking on this issue. I've reviewed what's expected and I'm confident I can meet the criteria.

    ℹ️ Repo Maintainers: To accept this application, review their application or assign @Adewumi99 to this issue.

  4. vjuliaife commented on Aug 25, 2026

    @vjuliaife

    @vjuliaife has applied to work on this issue as part of the Stellar Wave Program's 8th wave.

    Hi, I would like to work on this

    ℹ️ Repo Maintainers: To accept this application, review their application or assign @vjuliaife to this issue.

  5. rahimatonize commented on Aug 25, 2026

    @rahimatonize

    @rahimatonize has applied to work on this issue as part of the Stellar Wave Program's 8th wave.

    Hi maintainer ,can I please work on this issue , thank you

    ℹ️ Repo Maintainers: To accept this application, review their application or assign @rahimatonize to this issue.

  6. drips-wave commented on Aug 25, 2026

    @drips-wave

    Congratulations, @vjuliaife! 🎉 Your application was accepted by the repo's maintainers, and the issue is due on August 31, 2026.

    🧑‍💻 @vjuliaife: Please resolve the issue such that the repo's maintainers have enough time to review your contribution before the due date. You'll earn Points for completing the issue on-time, which will make you eligible for a share of the Stellar Wave Program's reward pool.

    Warning

    When opening a PR, please link it to this issue to ensure it gets tracked accurately. Points are awarded when this issue is marked as completed by the maintainer.

    🤠 Repo maintainers: Please keep an eye on the contributor's progress and review their work before the due date. You can manage this issue, including adjusting its complexity and points, here.

    🌊 Happy Wave 🌊

  7. drips-wave commented on Aug 26, 2026

    @drips-wave

    This issue has been completed by @vjuliaife as part of the Stellar Wave Program's 8th Wave 🥳

    😎 @vjuliaife: You earned 200 Points for completing this issue! After the current Wave ends, you'll be eligible for a percentage of the Wave's reward pool based on the percentage of total points you've earned. Learn more here. You can also Leave a review to share your experience working on this issue.

    🧑‍💻 Repo maintainers: How'd the contributor do? Leave a review to share your experience working with them.

  8. removed
    Stellar Wave
    on Oct 15, 2026
  9. added
    Stellar Wave
    on Oct 15, 2026
  10. removed
    Stellar Wave
    on Oct 15, 2026
  11. added
    Stellar Wave
    on Oct 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Stellar Wavearchitecturebugdocumentationgood first issuesecurity

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions