Jump to content
Crypto Front Page

Crypto networks, markets and policy

Cross-chain message passing: AMB shows how calls travel

What is cross-chain message passing? A source contract emits a call, bridge validators attest to it, and a destination bridge executes it after the required signatures arrive.

The Crypto Front Page Desk4 min read

Cross-chain message passing: AMB shows how calls travel

Cross-chain message passing carries a contract call from a source chain to a destination chain through a bridge and its validators. The source contract sends the call’s target and data; validators attest to the message; then the destination bridge submits the call for execution.

  • Source contract: starts the message with a target contract and encoded call data.
  • Bridge validators: observe the request and sign the same message until the required threshold is reached.
  • Destination bridge: uses the collected attestations to call the target contract on the other chain.

The Arbitrary Message Bridge (AMB) carries arbitrary contract calls between Ethereum and Gnosis Chain. Gnosis Bridge is useful background here: it lets users move tokens and messages between those chains. The Gnosis Chain AMB documentation explains how the bridge carries data and triggers contract functions.

How does one AMB call travel from Ethereum to Gnosis Chain?

Take a DAO contract on Ethereum that needs to change a parameter in a contract on Gnosis Chain. It calls the AMB with the destination contract as the target, the encoded parameter-setting call as calldata, and a gas limit for execution. The gas limit gives the destination call room to run.

The AMB records the request in an event. Bridge validators watch for that event, check the message, and sign it. Once enough validators have signed the same message, the destination AMB can submit it and call the Gnosis Chain contract with the encoded data. The target sees the change as a contract call on Gnosis Chain; the source contract did not directly reach across chains.

Think of validators as a relay that checks and carries a sealed instruction. Chains cannot read each other’s state directly, so the destination needs a way to verify that a source-chain request was approved before acting on it. The validator threshold supplies that attestation under the bridge’s trust model.

Delivery depends on direction. For Ethereum-to-Gnosis Chain messages, validators deliver the message automatically once the threshold is reached. From Gnosis Chain to Ethereum, the signatures are collected first, and someone must submit them on Ethereum before the message executes.

There is a separate security check at the destination. When the target contract is called through AMB, its msg.sender is the AMB contract, not the original DAO. The receiver should check AMB’s messageSender() and messageSourceChainId() against the expected source contract and chain. Those checks establish who originated the bridged call. Without the sender check, a call routed through the bridge from any source contract could trigger the receiver’s privileged action.

That same message layer supports token transfers. Omnibridge is built on AMB messages: a transfer carries an instruction to mint a representation on the destination or unlock tokens held there. The token operation is therefore a use of cross-chain messaging, with bridge contracts interpreting the message as a mint or unlock instruction.

Is a token bridge the same as a message bridge?

A token bridge moves assets by sending messages that tell destination contracts what token action to take. AMB carries arbitrary contract calls, while Omnibridge uses AMB messages for token transfers. The message bridge is the communication layer; the token bridge adds the rules for minting or unlocking assets.

Who runs the validators on a bridge?

Bridge validators are entities that monitor source-chain events, validate requests, sign messages, and help deliver them to the destination. A threshold of signatures is required for execution, so the receiver relies on that validator set rather than reading the other chain itself.

What should I learn next about receiving AMB calls?

How do I build a contract that receives Arbitrary Message Bridge calls?

Make the receiver accept calls only from the expected AMB, then check messageSender() and messageSourceChainId() against the authorized source contract and chain before changing state. These checks connect the destination call to its origin.

How much gas limit should I set for a bridged message?

Set a gas limit that gives the destination function enough gas to complete its work. The right amount depends on that function’s execution, so estimate the destination call rather than assuming the source transaction’s gas covers it.