Introducing a new way to review your PRs.

Read the announcement

lfdt-ibc / ibc

The Inter-Blockchain Communication Protocol (IBC) is a neutral, open standard for secure cross-ledger interoperability

View on GitHub

18 documents · Updated Nov 23, 2026

docs / link-attestation-and-transactions

Attestation and transaction submission

IBC Link turns observed packet activity into chain operations that an EVM chain can verify. It combines signed claims from an attestation set with a state update and packet proofs. It then builds and submits a transaction to the destination router. This page focuses on that chain-facing path. See Link relayer system for the wider system model and Link relay execution for packet lifecycle behavior.

Chain-facing relay path

The relay path separates trust, proof assembly, transaction encoding, and broadcast. Attestors establish what a counterparty chain claims at a height. The relayer turns those claims into an attestation proof. It places the proof beside packet operations and sends the resulting call to the chain that owns the tracked client.

This diagram shows how packet activity becomes a router transaction.

flowchart LR
    E[Packet event] --> H[Provable height]
    H --> A[Attestor claims]
    A --> Q[Quorum-checked attestation]
    Q --> P[State and packet proofs]
    P --> B[EVM router calldata]
    B --> S[Signed chain transaction]
    S --> R[Router updates client and packet state]

The same path supports three packet operations:

OperationClaim about the counterpartyRouter action
ReceiveA packet commitment existsDeliver the packet on the destination chain
AcknowledgeAn acknowledgement commitment existsProcess the acknowledgement on the source chain
TimeoutA packet receipt does not existRefund the packet on the source chain

The relayer first selects one height that the attestation quorum can prove. It uses that height for both the client state proof and the packet claims so the router checks one consistent view of the counterparty state. A timeout also requires the packet timeout time to be at or before the timestamp that the quorum can prove. See Link chain connectivity for the chain read model and Link runtime and services for process wiring.

Attestation integration

Attestation claims

An attestation is a signed claim for one block height. A state claim carries the height and block time. A packet claim carries the height and compact commitment data for one or more packets. The claim also carries the signatures that an EVM attestation light client can verify.

The packet claim type selects the fact being proved:

  • A packet commitment proves that a send packet is still committed.
  • An acknowledgement commitment proves that the destination chain wrote an acknowledgement.
  • Receipt absence proves that no receipt exists for a timed-out packet.

Local attestors read block headers and commitments from their watched EVM chain. They reject heights that are not yet safe under their finality setting. They also check packet data against the stored commitment before they sign a packet claim. This keeps the signature tied to the chain data rather than to an unchecked request.

Attestation signatures use separate domain tags for state and packet claims. The EVM form is a recoverable signature. This lets the relayer and the contract recover the signing address from the claim. References: cli/…/service.go• L20-76, link/…/local.go• L77-139, link/…/local.go• L142-193, cli/…/signing.go• L19-46

Attestation sets

The tracked client on the receiving chain defines which attestor addresses it trusts and how many distinct signatures it needs. Link reads that set from the chain. It then matches configured local and remote attestors by watched chain and signing address.

The match happens per client direction. An attestor that watches the counterparty chain is useful for that client only when its address is in the client’s on-chain set. Link fails setup when fewer reachable matching attestors exist than the on-chain threshold. Duplicate signing addresses cannot add independent votes.

This relationship makes on-chain client configuration the authority for quorum membership. Local attestors use a configured signer. Remote attestors query their service’s Info operation during setup to learn their chain and signing address before Link matches them. References: link/…/resolve.go• L17-36, link/…/resolve.go• L39-101, link/…/client.go• L229-252, cli/…/remote.go• L33-52

Attestation service

The attestation service gives a relayer access to local or remote attestors through one common contract. It exposes identity, the latest attestable height, state attestations, and packet attestations. A remote attestor uses the same calls over the Connect RPC interface. Each request has a short limit so an unavailable service does not block the whole process indefinitely.

Remote setup first calls Info to resolve the service identity. An unreachable or otherwise unresolvable remote attestor is skipped, while an invalid TLS configuration is treated as a configuration error. Local attestors fail setup when their chain client or signer cannot be resolved. These rules let transient remote outages leave other configured attestors usable without hiding local wiring errors.

The service reports domain errors in terms that callers can act on. For example, an unknown attestor is a not-found condition, while a requested height beyond finality is a failed-precondition condition. The server maps these errors at the transport boundary instead of changing the attestation rules.

The attestor process is stateless. A relayer process can also serve local attestors in dual mode, while remote attestors remain separate services. References: proto/…/attestor.proto• L9-22, proto/…/attestor.proto• L24-89, link/…/attestor_handler.go• L17-33, link/…/attestor_handler.go• L55-152, link/…/bootstrap.go• L59-82, link/…/bootstrap.go• L138-182, cli/…/remote.go• L31-127, cli/…/resolve.go• L17-85, cli/…/resolve_test.go• L16-95

Proof assembly

Quorum proof generation

The attestation proof generator turns attestor responses into a proof accepted by the EVM light client. It queries the selected attestors in parallel. It keeps signatures that recover to valid signers, groups responses by exact attested data, and requires one data value to reach the configured number of distinct signers.

The generator uses the quorum result in two ways:

  • A state proof contains the agreed state claim and its signatures.
  • Each packet proof contains the agreed packet claim and its signatures.

One packet request may cover a batch. The resulting proof is shared by the packets in that batch because the claim contains the complete packet set. The generator still returns one proof entry for each input packet so the relay layer can keep packet order aligned with router calls. References: link/…/quorum.go• L20-25, link/…/quorum.go• L27-105, link/…/quorum.go• L108-160, link/…/generator.go• L19-60, link/…/generator.go• L63-124

EVM proof format

The EVM integration uses ABI-shaped data shared by the attestor, the relayer, and the attestation light client. State claims contain a height and timestamp. Packet claims contain a height and compact pairs of commitment path and commitment value. The outer proof contains the agreed claim bytes and the set of signatures.

The proof generator checks that the returned claim height and packet count match the request before it encodes the outer proof. These checks stop a valid signature over the wrong relay input from becoming a chain operation. References: link/…/encoding.go• L11-30, link/…/encoding.go• L66-136, link/…/generator.go• L36-60, link/…/generator.go• L90-124

Transaction construction

Relay transaction intent

The relay processors combine a client update with packet operations before asking a chain-specific builder for calldata. A transaction intent contains only a target address and data. This keeps transaction assembly separate from signing, nonce choice, gas policy, and broadcast.

For EVM chains, the builder places the following calls into one router multicall:

  1. Update the tracked light client with the attestation state proof.
  2. Perform one receive, acknowledgement, or timeout operation for each packet.

The builder returns the router address and the encoded call data as a relay transaction. The EVM route expects one transaction for a batch. The processor waits for the target chain clock to catch up before it submits the intent. It then records the returned transaction hash, time, and relayer address for every packet in the batch. References: link/…/batch_relay.go• L54-70, link/…/batch_relay.go• L68-137, cli/…/txbuilder.go• L16-24, cli/…/evm.go• L47-90

Router operations

The router receives the proof and packet data through operation-specific calls. Receive uses a packet commitment proof. Acknowledgement uses an acknowledgement proof plus the recorded acknowledgement bytes. Timeout uses a receipt-absence proof. EVM heights use revision zero because the EVM chain model has no separate revision or epoch.

The router binding also defines read paths that support this flow. It can read client state, packet commitments, counterparty client IDs, and the attestation set. It exposes the attestation light client’s update and verification methods that correspond to the proofs Link places in relay calldata. References: link/…/evm.go• L92-123, link/…/evm.go• L125-203, link/…/client.go• L204-252, link/…/attestation.go• L311-355, link/…/attestation.go• L495-555, link/…/attestation.go• L620-639

Relay simulation

The transaction submitter can run a prepared relay transaction as a read-only EVM call before broadcast. It decodes the multicall result in execution order and reports whether the client update and each packet operation would succeed. A failed operation includes a decoded contract error when the chain provides one. This gives the IBC CLI a per-operation preflight result without changing chain state. References: cli/…/txsubmitter.go• L18-29, cli/…/simulation.go• L22-78, cli/…/revert.go• L29-78

Transaction submission

Submitter responsibilities

The transaction submitter is the boundary between a prepared relay intent and an EVM chain. It exposes simulation, submission, and retry decisions through one chain-level contract. It owns the chain signer, transaction nonce, fee values, gas estimate, signature attachment, and RPC broadcast. It returns the hash and identity data that the relay pipeline uses to track the operation.

Before broadcast, the EVM submitter checks that the target is a contract and that the chain supports EIP-1559 fees. It reads the current base fee and tip suggestion. It estimates gas for the intent and selects a nonce from the chain’s mined and pending views. It then creates an EIP-1559 transaction, signs its digest with the configured ECDSA signer, verifies the recovered sender, and sends it through the chain RPC. A node response that says the transaction is already known is treated as a successful broadcast.

Submission calls are serialized per submitter, while a bounded number of nonces can remain in flight. A stalled lowest nonce can be reused after the configured pending period; before then, a full in-flight window leaves the work for a later dispatch. A configured chain and signer pair has one submitter, so routes that use the same pair share nonce and broadcast control. If a replacement is underpriced, the submitter raises the fee and tip within a ceiling based on the fresh estimate. References: cli/…/txsubmitter.go• L18-35, cli/…/txsubmitter.go• L37-95, cli/…/evm.go• L24-75, cli/…/evm.go• L111-174, cli/…/evm.go• L176-215, cli/…/txops.go• L19-67, cli/…/txops.go• L70-120

Submission retry

The submitter does not treat a broadcast as proof that the relay completed. The pipeline keeps the submission details and later asks the submitter for its chain status. A transaction with a failed receipt is retryable. A transaction with no receipt is retryable only after its pending period expires. A successful receipt is not retryable.

When a retry is due, the matching processor clears the stored transaction details. The next dispatch pass can then rebuild the proof and relay operation instead of sending the same recorded operation blindly. A transaction that is still pending remains recorded. This prevents duplicate work while the chain may still include it. Receipt checks also account for gas cost only for transactions that this submitter recorded. The cost is counted from the receipt’s gas used and effective gas price. References: cli/…/txsubmitter.go• L23-27, cli/…/evm.go• L217-235, link/…/retry_recv_packet.go• L15-52, link/…/retry_ack_packet.go• L16-51, link/…/retry_timeout_packet.go• L16-55, cli/…/metrics.go• L113-148

Submission metrics

The submitter exposes chain and wallet signals for operating the chain-facing path. It tracks cumulative EVM gas spent for submitted transactions and reports the current native-token balance for each configured wallet. These signals use chain_id and wallet labels so operators can relate fee use and funding to one signer on one chain. See Link operational observability for the wider monitoring model. References: cli/…/metrics.go• L49-91, cli/…/metrics.go• L159-210

Balance reads use a short cache so telemetry collection does not repeatedly query the chain. A failed balance read produces -1 for that observation and stays cached until the refresh interval passes. The metric tests cover wallet separation, exact gas accumulation, foreign transaction exclusion, failed receipts, expired pending transactions, and balance refresh behavior. References: cli/…/metrics.go• L176-239, cli/…/metrics_test.go• L26-391

Configuration relationships

The chain-facing path depends on three linked configuration choices. A chain names its RPC endpoint and ICS26 router. Each connection end names the client, the signer that submits transactions on that chain, and the attestation client type. The attestor list names local signing services or remote attestor endpoints.

The bootstrap process resolves these choices in order. It creates chain clients and signers. It resolves local attestors from those clients and signers. It resolves remote attestors by checking their endpoint and querying their identity. An unreachable remote attestor is skipped so other entries can continue. An invalid TLS block, a missing local chain client, or a missing local signer stops setup. Link then matches the resolved attestors to each on-chain client set and creates proof generators, EVM transaction builders, and submitters for the unique chain and signer pairs. A missing chain, signer, router, attestor match, or submitter prevents a usable relay path from being built. References: link/…/config.go• L35-83, link/…/config.go• L270-295, link/…/relayer.go• L28-78, link/…/bootstrap.go• L41-111, cli/…/resolve.go• L17-85, cli/…/resolve_test.go• L16-95

For operational context, read Link deployment and persistence. It explains how process roles and stored relay state affect the lifetime of these submissions.

Change checklist

When these files or sections are changed, remember to consider these:

  • Keep the attestation data layout, domain tags, signature form, and contract verification rules aligned across the attestor encoder, quorum verifier, proof encoder, and deployed attestation light client.
  • Keep the commitment type mapping aligned across the public attestor protocol, local commitment lookup, proof-kind selection, and router operation selection.
  • Keep remote attestor identity discovery aligned with the chain and address used when matching the on-chain trust set. Treat endpoint and TLS errors according to their intended configuration or availability class.
  • Keep the on-chain attestor address set and threshold compatible with the names and signing addresses that the relayer can resolve from local and remote attestors.
  • Keep the ClientUpdate, packet proof height, and packet operation inputs on the same provable counterparty height.
  • Keep each connection end’s transaction signer aligned with the submitter selected for the chain where that end’s router call runs.
  • Keep simulation call ordering aligned with multicall result ordering and router method decoding so each reported operation refers to the correct call.
  • Keep nonce ownership, replacement fee limits, and pending-timeout behavior aligned with the chain’s transaction pool rules.
  • Keep submission records and retry clearing aligned with the receipt lookup rules so a failed or expired transaction can be rebuilt without losing a completed relay.
  • Keep transaction ownership tracking aligned with receipt handling so gas cost is counted once for locally submitted transactions and not for foreign transactions.
  • Keep wallet metric labels and native-token conversion stable so dashboards continue to distinguish chain and signer pairs.

Important failure modes

TriggerConsequenceGuard
Fewer matching attestors than the client’s on-chain thresholdThe proof generator cannot be created for that client directionMatch watched chain and signing address against the on-chain attestation set during setup
Remote attestor endpoint is unreachable or its Info call failsThat configured attestor is skipped and may leave too few members for quorumKeep remote endpoints reachable and check the final resolved set against the on-chain threshold
Remote TLS configuration is invalidSetup fails instead of starting with a bad secure transportValidate CA and TLS settings before resolving the remote endpoint
Attestors sign different claim bytesNo quorum proof is producedGroup responses by exact attestation data and require one group to reach the distinct-signer threshold
Requested height is beyond an attestor’s safe heightState or packet attestation fails and no relay transaction is builtResolve a quorum-provable height and apply local finality rules
Packet commitment is missing or does not match the packetThe packet proof is rejected before submissionRead the commitment at the requested height and compare it with the packet claim
Relay simulation finds a multicall operation failureThe CLI can report the failed client or packet operation before broadcastSimulate the prepared multicall and decode each result in execution order
EVM target has no contract code, the chain has no base fee, or the signer does not match the configured addressTransaction construction stops before signingValidate the target contract, require EIP-1559 chain support, and verify the recovered sender
Replacement fees reach the configured ceilingA pending nonce cannot be replaced by another broadcast attemptKeep fee increases bounded and wait for the pending timeout or chain progress
Broadcast transaction fails or stays pending past retry expiryThe packet can remain stuck until the recorded submission is clearedCheck the receipt and clear only failed or expired submissions for a later rebuild
Receipt is checked more than once or belongs to another relayerGas-spend totals can be overstatedRecord ownership at broadcast and consume each owned receipt once
Balance RPC read fails during metric collectionThe wallet balance signal is unavailable for that observationReport -1 and retry after the balance cache interval

Key files

FileWhy to read it
link/…/local.goShows how a local EVM attestor turns finalized chain data into signed state and packet claims.
cli/…/remote.goShows how remote identity discovery and attestation requests use the common attestor contract.
cli/…/resolve.goShows how configuration selects local and remote attestors and classifies setup errors.
cli/…/resolve_test.goShows the guarantees for local dependency errors, unreachable remote services, and invalid remote TLS.
link/…/resolve.goShows how Link binds a client’s on-chain trust set to configured attestors.
link/…/quorum.goShows the agreement and signer checks that make a proof usable.
link/…/generator.goShows how quorum results become state and packet proofs.
cli/…/evm.goShows how one EVM router transaction combines a client update and packet operations.
link/…/batch_relay.goShows the handoff from proofs and packet events to a transaction intent.
cli/…/evm.goShows the submitter boundary and the rules for EVM nonce selection, fee replacement, broadcast, and retry.
cli/…/simulation.goShows how the IBC CLI preflights a multicall and returns per-operation outcomes.
cli/…/txops.goShows the shared EVM transaction rules for fee estimation, gas estimation, signing, and broadcast.
cli/…/txsubmitter.goDefines the simulation, submission, and retry contract and the one-submitter-per-chain/signer mapping.
cli/…/revert.goShows how EVM RPC and contract errors become readable relay failure reasons.
cli/…/metrics.goShows how gas spend and wallet balance signals are tied to chain and signer pairs.
cli/…/metrics_test.goShows the guarantees for transaction ownership, one-time gas accounting, and cached balance observations.
link/…/client.goShows the chain reads that supply packet commitments and attestation-set data.
proto/…/attestor.protoDefines the service contract for local and remote attestation access.