Skip to content

[Emergency Release] v1.22.27 - #965

Merged
CassioMG merged 2 commits into
emergency-releasefrom
v1.22.27
Jul 31, 2026
Merged

CassioMG merged 2 commits into
emergency-releasefrom
v1.22.27

Conversation

@github-actions

@github-actions github-actions Bot commented Jul 31, 2026 •

Copy link
Copy Markdown
Contributor

fix(send): derive the token contract from the asset (#966)

github-actions Bot and others added 2 commits July 31, 2026 15:08
#964) (#966)

When a classic asset was sent to a contract (C...) address, the Soroban
transfer used `recipientAddress` as the invocation target. The token
contract is a property of the asset, so this invoked whichever contract
the destination address pointed at and moved the asset that contract
governs rather than the selected one. The amount was also always scaled
by the selected asset's decimals, which the invoked contract then
reinterpreted with its own.

Derive the target from the asset instead: its Stellar Asset Contract
address, which follows deterministically from (code, issuer, network
passphrase). Native XLM and custom Soroban tokens already resolved
correctly and are unchanged.

Also drop the surrounding try/catch, whose handler re-dispatched on
`isCustomToken` inside a branch where it is provably false, and add a
guard refusing to send a token to its own contract address — such a
transfer is credited to an address with no spender.

Tests cover all three branches so they cannot be transposed again.

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
@CassioMG CassioMG self-assigned this Jul 31, 2026
@github-actions

Copy link
Copy Markdown
Contributor Author

iOS Simulator preview build is ready: https://github.com/stellar/freighter-mobile/releases/tag/untagged-667a0c62a752bc54748a (SDF collaborators only — install instructions in the release description)

@CassioMG
CassioMG merged commit a5496d5 into emergency-release Jul 31, 2026
120 of 129 checks passed
@CassioMG
CassioMG deleted the v1.22.27 branch July 31, 2026 15:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant