👉🏻 For cross-chain interactions, those who often play games must be very familiar with it. We often need to use various cross-chain tools (such as cross-chain bridges) to transfer GAS from Ethereum to various L2, L3, and even transfer assets between various heterogeneous chains.
In today's Web3 ecosystem, cross-chain facilities that connect various blockchains have become indispensable.
💡 Are you curious about how cross-chain interaction is accomplished?
✨ Mainstream cross-chain facilities mainly use the following technologies:
Hash locking, sidechains/relay chains, bridges and cross-chain protocols
▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰
1️⃣ Hash Chain Locking (HTLC)
Hashed Time Lock Contract (HTLC) is a mechanism that enables two parties to trade without trusting each other. HTLC is mainly used for atomic swaps of cryptocurrencies. The implementation steps are as follows:
Create a transaction:
One party generates a password and places its hash into a smart contract, which releases the funds only when the correct password is provided.
Time lock:
The contract also includes a time lock, and if the secret is not provided within a specified time, the funds are returned to the original sender.
Cross-chain operations:
When one party submits a contract on one chain, the other party creates a contract with the same hash on another chain, initiating the exchange process.
Unlock and Exchange:
One party discloses a secret to claim the funds on the other party’s chain, while the other party uses the same secret to unlock the funds on the original chain.
▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰
2️⃣ Sidechain
A sidechain is a blockchain that runs independently from the main chain, allowing assets to be transferred between the two.
Two-way anchoring:
The sidechain is connected to the mainchain through a two-way anchor. Assets can be locked on the mainchain and released in the form of tokens on the sidechain, and vice versa.
SPV Proof:
Sidechains can use simplified payment verification (SPV) to prove the status of a certain asset and ensure the validity and security of cross-chain asset transfers.
Merged Mining:
Some sidechain projects use joint mining technology, allowing miners to ensure the network security of both the main chain and the sidechain at the same time.
▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰
3️⃣ Relay Chain
Connecting Parachains:
The relay chain serves as the main coordination chain, and each parachain exchanges information and assets through the relay chain.
Shared Security:
All parachains share the security provided by the relay chain, and transactions require verification and consensus of the relay chain.
Cross-chain messaging:
The relay chain uses the Cross-Chain Messaging Passing (XCMP) protocol to allow parachains to communicate and transact directly with each other.
💡 Typical projects using relay chains: Polkadot $DOT
▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰
4️⃣ Bridge
Bridging technology is used to connect two independent blockchains, allowing assets and data to be interoperable.
Decentralized Bridge:
Use smart contracts to verify and record cross-chain transactions without the need for a centralized third party.
Centralized Bridge:
Relying on a trusted entity as an intermediary to transfer and lock assets is fast but less secure.
Light client verification:
Bridging typically involves implementing a light client of one chain on another chain to verify transactions and asset status.
▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰
5️⃣ Inter-chain protocol (IBC)
Interchain Communication Protocol (IBC):
Allows independent blockchains to send messages and assets by creating connections and channels.
Connections and Channels:
Connections are used to track the consensus state between chains, while channels are the endpoints that send packets on the connection.
Packet transmission:
Through channels, chains can send ordered and confirmed data packets, enabling interoperability of assets and information.
💡Classic projects using cross-chain protocols: Cosmos $ATOM
▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰▰
👉🏻 There are also some new cross-chain projects, such as Wormhole
And Axelar $AXL who was listed on Binance#Binancesome time ago
wait.
A combination of these technologies is used to achieve more complex functions and strong security.
✨ If you have any opinions, you are welcome to discuss in the comment area. If you think it’s good, you can also give PumpPump a like and follow ❤️