57892 sc insight long tokens will be stuck in the escrow if customers exclusively use usdc payments in paytovenue

  • Submitted on: Oct 29th 2025 at 11:45:45 UTC by @Josh4324

  • Report ID: #57892

  • Report Type: Smart Contract

  • Report severity: Insight

  • Target: https://github.com/immunefi-team/audit-comp-belong/blob/main/contracts/v2/platform/BelongCheckIn.sol

  • Impacts: Permanent freezing of funds

Description

Brief / Intro

In the BelongCheckIn contract, venue-deposited LONG tokens are held in an Escrow and primarily disbursed as subsidies during customer LONG payments (via payToVenue with paymentInUSDC = false). If all customers exclusively pay in USDC (paymentInUSDC = true), subsidy distributions never occur, leaving LONG funds in the Escrow without a direct redemption mechanism for venues. This can result in LONG deposits being permanently locked, as there are no functions allowing venues to withdraw LONG balances or otherwise redeem unused LONG.

Vulnerability Details

LONG deposits (recorded in Escrow as longDeposits) are only disbursed via distributeLONGDiscount, which is exclusively called in the LONG payment path of payToVenue to provide subsidies (subsidyMinusFees). If customers always choose USDC payments, this path is never triggered, and no LONG outflows occur. The contract lacks any venue-direct withdrawal, burn-to-redeem, or timed release for unused LONG.

Impact Details

Venue owners may be unable to access deposited LONG, leading to locked LONG funds.

circle-exclamation

References

  • Vulnerable code (reference line): https://github.com/immunefi-team/audit-comp-belong/blob/main/contracts/v2/platform/BelongCheckIn.sol#L421

Proof of Concept

Save the following test into file.test.ts and run:

yarn test test/v2/platform/file.test.ts

Example test output (shows LONG tokens remain in Escrow):

Notes / Next steps

  • The contract should provide a path for venues to reclaim LONG tokens that were deposited into Escrow but never distributed (for example: a venue-withdraw function, burn-to-redeem, owner-triggered distribution, or a timed/unclaimed-release mechanism).

  • Any proposed fix should preserve intended subsidy mechanics while ensuring deposited LONG cannot be permanently locked when customers exclusively pay in USDC.

Was this helpful?