Documentation

Cross-Chain Mechanism

Leveraging Hyperlane for secure, permissionless communication between Mantle and Sapphire

Why Hyperlane?

Cylend requires a messaging layer that is both fast (to minimize slippage/latency) andsecure (to protect asset release instructions). Hyperlane was chosen for its:

Modular Security

Customizable Interchain Security Modules (ISMs) allow Cylend to define its own trust model.

Permissionless

Anyone can run a relayer, preventing censorship of valid cross-chain actions.

Latency

Optimized for high-frequency updates, crucial for real-time lending health checks.

Message Lifecycle

1. Dispatch (Mantle)

PrivateLendingIngress calls mailbox.dispatch(). The message contains the encrypted payload and the destination chain ID (Sapphire).

2. Verification (ISM)

Hyperlane validators observe the event on Mantle. Once a quorum is reached, a merkle proof is generated attesting to the message's validity.

3. Processing (Sapphire)

The Relayer submits the proof to the Sapphire Mailbox. The Mailbox verifies the proof against the ISM and calls LendingCore.handle().

Interchain Gas Payment (IGP)

To provide a seamless "single-click" experience, Cylend uses Hyperlane's IGP (Interchain Gas Paymaster).

Users pay for the entire transaction flow in MNT on the source chain. The IGP contract collects this fee and incentivizes the relayer to execute the transaction on the destination chain (Sapphire), ensuring the user doesn't need to hold ROSE tokens.

Warning

Latency Note: Cross-chain messages typically take 15-30 seconds to finalize. The frontend UI handles this asynchronous wait state optimistically to keep the user engaged.