Skip to content
Access control Audit finding Advanced

The `sender` argument for the Solana `OnCall` instruction can be impersonated

The sender argument for the Solana OnCall instruction is not included in the message signed by observers, allowing a malicious observer to replace the sender address when executing the transaction. This lets an attacker impersonate any sender and call the destination program with a different address than the original CCTX initiator.

0x15 Follow with 0xkmr_, OhmOudits and 3 others

Originally disclosed on Sherlock

Source: https://github.com/sherlock-audit/2025-04-zetachain-cross-chain-judging/issues/312

Found by

0x15, 0xkmr_, OhmOudits, berndartmueller, ch13fd357r0y3r, shaflow01

Summary

The sender argument for the Solana OnCall instruction can be impersonated due to not being included in the message signed by the observers. This allows an attacker to call the destination program with a different sender address than the one originally initiated the CCTX.

Root Cause

The sender argument for handle_spl_token() and handle_sol() is provided to the called destination program as part of the OnCall instruction. For example, authorization checks can be implemented to verify the original CCTX sender.

However, the sender argument is not included in the message signed by the observers. This means the sender can be exchanged to any other address when calling the gateway's execute() or execute_spl_token() function. As a result, the sender can be impersonated by an attacker, allowing them to call the destination program with a different sender address than the one originally initiated the CCTX.

As Solana does not have a public mempool, exploiting these issues is difficult. However, a single observer could exploit this by frontrunning the outbound Solana transaction and replacing the sender. Or, the Solana RPC operator or the validator could also exploit it.

Internal Pre-conditions

  • A single malicious observer

External Pre-conditions

  • The destination Solana program has authorization checks that depend on the sender argument and distribute funds based on it.

Attack Path

  1. Attacker sends an outbound CCTX from ZetaChain to Solana to call a specific destination program. The attacker's address will be used as the CCTX sender.
  2. Observers vote on the outbound CCTX.
  3. The observer colludes with the attacker and replaces the sender (the attacker's address) with their target address that should be impersonated.
  4. The Solana transaction is executed, and the destination program is called with the impersonated sender address.
  5. Destination program checks the sender address and authorizes funds transfer to the impersonated address.

Impact

The sender argument for the OnCall instruction can be impersonated.

PoC

N/A

Mitigation

The sender argument should be included in the message signed by the observers.

Discussion

sherlock-admin2

The protocol team fixed this issue in the following PRs/commits: https://github.com/zeta-chain/node/pull/3896

gjaldon

The issue has been fixed by including the CCTX sender in the message hash.

The original report as published on Sherlock, by 0x15. Images and videos are our own copies; raw HTML is shown as text. View it on Sherlock.

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

Root cause

The sender argument is not included in the message signed by observers, so it can be altered without invalidating the signatures.

Impact

A malicious observer could impersonate the sender and cause the destination program to authorize funds transfer to an arbitrary address, though exploitation is difficult because Solana has no public mempool.

What the attacker needed

A single malicious observer; Destination program relies on sender for authorization

How it was found

  1. Attacker sends an outbound CCTX from ZetaChain to Solana to call a specific destination program, with the attacker's address as sender.
  2. Observers vote on the outbound CCTX.
  3. A malicious observer colludes with the attacker and replaces the sender with a target address to impersonate.
  4. The Solana transaction is executed, and the destination program is called with the impersonated sender address.
  5. The destination program checks the sender address and authorizes funds transfer to the impersonated address.

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.

When a cross-chain transaction is sent to Solana, observers sign a message to approve it. The sender address is not part of that signed message, so a malicious observer can change it without detection. This means the destination program might think the transaction came from someone else.

What is Access control?

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.

More by 0x15

View all

6 more disclosed reports, best first.

More from ZetaChain Cross-Chain

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Broken access control

The lesson behind this report.

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.