TON Observer processes each hash in the Outbound tracker and stores the result of the last nonce successfully processed
The TON Observer processes every hash in an Outbound tracker without stopping on errors, and the last successfully processed hash overwrites earlier results. A malicious Observer can add a failed withdrawal transaction with the same nonce so the outbound is recorded as failed, letting the sender claim both the withdrawal and a refund.
Source: https://github.com/sherlock-audit/2025-04-zetachain-cross-chain-judging/issues/375
Found by
g
Summary
When the TON Observer processes an Outbound tracker, it will process each hash without stopping if an error is encountered. The last tx hash successfully processed will overwrite any previous successful processing when it calls setOutboundByNonce(). This allows any malicious Observer to add the last tx hash to an Outbound Tracker to mess with the results intentionally.
Root Cause
Unlike the Bitcoin Observer, which will iterate every tx hash to find the truly included outbound, the TON Observer will only store the results of the last transaction it successfully processed as long as:
- It's a withdrawal transaction.
- The signer of the payload hash is the TSS address.
There is also no check that the transaction has incremented the nonce.
Internal Pre-conditions
None
External Pre-conditions
None
Attack Path
- Outbound 42 is a successful withdrawal where the sender has received their withdrawn amount.
- A malicious Observer can add the tx hash to the Outbound Tracker of Outbound 42 with a failed withdrawal transaction with the same nonce. This can naturally occur when multiple Observers try to broadcast the same Outbound transaction. They do this at the last moment to ensure their tx hash will dictate the observed status.
- When the Outbound Tracker for Outbound 42 is processed, their tx hash's results will be used, and it will be a receive_status of failed. This means the attacker can make a successful observation into a failed observation.
- Every Observer will vote on outbound 42 with a failed observation, marking it as a Pending Revert.
- The sender of the withdrawal ends up claiming both the withdrawal and the refund on their withdrawal, doubling their funds at the expense of Zetachain.
Impact
The protocol permanently loses funds equal to the withdrawal amount. The attacker/target will gain funds equal to their withdrawal amount, doubling their withdrawal amount.
PoC
No response
Mitigation
No response
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Impact
The protocol could permanently lose funds equal to the withdrawal amount while the sender gains the same amount again.
What the attacker needed
Control of a TON Observer node; a pending outbound withdrawal
How it was found
- Outbound 42 is a successful withdrawal where the sender has received their withdrawn amount.
- A malicious Observer adds a failed withdrawal transaction with the same nonce to the Outbound Tracker of Outbound 42.
- When the Outbound Tracker is processed, the failed transaction's result is used and the receive status is failed.
- Every Observer votes on outbound 42 with a failed observation, marking it as a Pending Revert.
- The sender claims both the withdrawal and the refund, doubling their funds.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
A cross-chain bridge watches the blockchain to confirm that a withdrawal really happened. Here, the watcher for the TON chain looked at several candidate transactions and kept only the result of the last one it could read, instead of checking which one was actually included. A dishonest watcher could slip in a failed transaction with the same number, so everyone recorded the withdrawal as failed and the user got a refund on top of the money already sent.
What is Business logic?
The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.