Your friendly neighborhood exchange offers several services and features that make operating in the crypto space easy, enjoyable, and profitable. But when you’re in this space long enough, searching for the elusive best APY, you find that every network offers a way to increase your bag and a CEX can move that money for you easily, but you’re interested in a particular network and it’s unsupported. Your journey is over as you stop just inches from the cliff’s edge overlooking a void as deep and as empty as outer space.
This is a problem that talented developers have been working to solve since DeFi escaped the clutches of the Ethereum network: Trustless cross-chain composability and unified liquidity. This void hasn’t stopped users from moving funds across the galaxy, it just isn’t all that safe or trustless. If you’re okay with the swaps AscendEX offers, then stop reading. Otherwise, let’s explore the cross-chain services that travel this void between networks every day.
Just like the eternal Tao, the Bridge Trilemma exists around us but can’t be completely grasped, we can only get closer. Current novelty Layer Zero Labs posits that a bridge may only satisfy two of three criteria:
A guarantee that a transaction will be successfully committed to the destination blockchain while implying that the liquidity exists there to fulfill the request.
The ability to combine native assets and/or smart contracts into a single transaction between networks. i.e., BTC for ERC-20 or smart contract instructions.
A single standard for native liquidity provision to be used in any given transaction.
We’ll take a closer look at the three (in my opinion) categories of cross-chain solutions available. And with all the hours of knowledge, wisdom, and talent working on the cross-chain question, these are the best solutions we have. These categories are Wrapped Token Bridges, Exchange Bridges, and Messaging Brides. Try to see which of the two criteria each of these categories satisfies, be careful as one of the categories claims all three.
Most of the initial attempts at cross-chain interoperability existed to bring Bitcoin to DeFi. Using the Ethereum ERC-20 standard to create a token tied to the value and supply of BTC using price oracles such as Chainlink. It’s a simple tool that has branched out from just BTC to any other token an organization was willing to support with their code and man hours. If there is a market for it, a bridge will be built.
Though this is a crude tool, it is an effective one: The user deposits their token into a ‘trusted’ vault. The vault sends instructions to another vault on the destination chain to mint the ‘wrapped’ asset equal to the amount deposited. The user now has the wrapped asset to do as they please with it as if it were the original asset. But an important distinction has to be made: This is not the original asset; this is only a totem (backed by cryptography) of the original asset.
Once the user is done at the DeFi casino they must interact with the bridge to receive their original asset in a sort of reverse order of the initial series of transactions: The user deposits their ‘wrapped’ asset to be ‘burned’. The bridge then issues instructions to release the original tokens equal to the burnt amount and deposit them into the user’s wallet. Once that transaction is finalized on the destination blockchain, the user now has their funds and may do what they please with them.
You can see why this method may be problematic to the crypto maximizer as this process is exactly like working with a bank or currency exchange and is therefore not trustless. This method is designed using properties (1) and (2) of the trilemma. There is no unified liquidity as each bridge must maintain a treasury of its funds. This opens this method to a single point of attack which has occurred before.
In early 2020 the Wormhole bridge (A Solana bridge) was taken for 120K ETH where Jump Trading bailed out the bridge for approximately USD 325 Million. A few weeks later Ronin Bridge (An Ethereum bridge) was hacked for approximately 173K ETH and USD 25.5 Million. As you can see, the bridge method while simple and effective is vulnerable to attacks at the treasury layer.
While the Bridging method allows users to mint synthetic wrapped assets for use on another network, it does not give the user a native asset on the other side of the bridge without the further infrastructure in place.
The decentralized method is essentially a purist’s method as the user relies on a network of decentralized nodes to fulfill transactions as opposed to a centralized third party.
A few DEXs are providing this cross-chain service but we’ll focus on the Thorchain network and their native token RUNE since they have a history that covers all our educational needs. Thorchain (RUNE / USDT) started as a BEP-2 (Binance Smart Chain) token exchange but later migrated its infrastructure to service other networks such as BTC (BTC / USDT), ETH (ETH / USDT), DOGE (DOGE / USDT), and ATOM (ATOM / USDT) to name a few from the growing list. They’ve also absorbed some juicy attacks.
Before we can understand the anatomy of a token swap on Thorchain we must summarize each role on the Thorchain network since they are all different but all equally important. First, understand that the RUNE token is the incentive, much like any other network, each role is fulfilled with the incentive of receiving RUNE for honest execution of their role.
The skeleton of the Thorchain network is comprised of a finite list of active nodes providing economic security through a minimum bond of RUNE. A node operator is responsible for creating blocks on Thorchain’s internal blockchain, observing external blockchains, and maintaining the integrity of this immutable ledger. Nodes are also responsible for securing the vaults/treasuries of incoming assets as well as the internal vaults for outgoing transactions. Any swap made on the network relies on the secure and honest execution of these responsibilities. These operators facilitate the trades that happen on Thorchain.
The most secure blockchain in the world is nothing without the user. The user role is divided into two functions: The swapper and the arbitrageur. They both perform the same function but with different outcomes. A swapper is an everyday user, they buy BTC for ETH solely because they want buy ETH, but the arbitrageur does the same thing for two reasons:
1) Buy and sell assets at a discount and premium
2) To balance liquidity pools and maintain the market price peg
This incentive to buy/sell tokens at a premium end up removing the need to interact with price oracles to determine an asset’s price. The price of an asset is maintained through economic incentives and contained inside the ecosystem.
We have a sturdy skeleton, and a robust nervous system but a living creature needs one more element for life, it requires blood. In DeFi liquidity is everything, it’s a simple concept but imperative for any DeFi protocol to function. Having said all that, these users simply provide liquidity to the network and collect fees therein for everyone else to do their job.
Every pool in Thorchain is paired with RUNE so BTC would be BTC/RUNE and ETH would be ETH/RUNE. So each swap is not exactly a 1:1 swap for BTC/ETH, instead the transaction is handed off to the protocol to facilitate a BTC/RUNE: RUNE/ETH transaction with the fee being paid with the incoming (BTC) and network (RUNE) asset.
Some argue that Thorchain’s design contains all three pillars of the trilemma, I hope you see how this network does not explicitly fulfill (2) as the asset swap is not one transaction but two. Otherwise, transactions are finalized on the destination chain with guaranteed liquidity and each pool can be used interchangeably in the network to fulfill a given swap.
Last year Thorchain was the victim of a USD 4.9M attack stolen from liquidity pools. Soon after they were the victim of a white hat attack and taken for USD 8M.
You may have noticed each bridging solution requires trust in a third-party treasury of varying security where the funds must travel in the void between networks. There is a way to avoid this dangerous journey that does align with the original thesis of trustless finance: Don’t send funds through the void, send IOUs through the void.
Layer Zero is a new approach to this bridging trilemma using a messaging system in tandem with a liquidity provision algorithm built on top known as Stargate Finance. This is Layer Zero Labs’ attempt to solve all three properties of the bridging trilemma.
Layer Zero’s messaging infrastructure removes a considerable amount of complexity (if not all of it) using three components:
Layer Zero Endpoints: A series of smart contracts located on each supported blockchain. These are the communications channels needed for cross-chain composability.
Relayers: An off-chain service that only verifies the proof (the cryptography) for a specific transaction.
Oracles: An independent third-party service (i.e., Chainlink) that reads the block header from one chain, verifying the transaction has been requested, to the other chain.
This protocol alone cannot perform cross-chain swaps but requires another application built on top of it called Stargate Finance. As stated earlier: liquidity is everything. Stargate is a service that provides liquidity pools for assets on each supported chain. A USDC pool on Stargate, using their proprietary algorithm called ∆Bridge, maintains a balance of each native protocol version of the asset.
Let’s suppose you want to swap ETH USDC for AVAX USDC. You’d find an AMM attached to a Layer Zero endpoint, locate that pool, and use the swap UI as you would normally. When the confirm transaction button is pressed a few things happen:
A message containing transaction instructions is created and sent from the endpoint to Stargate (confirmed using the Relayer/Oracle tandem). Then stargate releases that liquidity into the destination wallet. All through Layer Zero’s messaging protocol.
Stargate as a liquidity provider built on top of the Layer Zero protocol does appear to solve for (1), (2), and (3) of the trilemma pillars. Stargate has many pools composed of many native tokens for many given assets while being facilitated by the security of the messaging protocol beneath. No assets travel between the void as they exist on-chain.
Layer Zero is new as it has been in development since 2021 so there haven’t been any hacks or exploits. But remember, this is crypto, and everyone gets their turn. We’ll have to wait and see how it happens.
I’d like to thank you, dear reader, for sticking through this article. Cross-chain composability is complex as we are plotting pins and strings on a bulletin board with exponentially growing complexity as more applications enter the series of instructions needed to perform a given DeFi function.
I hope this helps you decide which tool you need to explore the networks that exist to give you degenerate returns on your investments. Happy aping.