Bankless: Discussing the future of Ethereum and L2
In an article published by Bankless on December 22, Bankless guest author Viktor Bunin discussed and predicted the future of Ethereum and L2.
JinseFinanceSource: Vernacular Blockchain
Why must liquidity flow seamlessly?
Last weekend, all my Farcaster friends were talking about a hot new coin, DEGEN on Base. Feeling FOMO (fear of loss), I checked my Rabby wallet to see how much I could invest:
"Cool, I can put $500 into this coin and just need to sell some other assets. However, my portfolio looks like What does it look like?"
"Oh NO"
< /p>
Almost every Token is on a different second layer network. In order to get DEGEN, I have to perform multiplebridgings in sequence, and even though the fees are low, it's still a frustrating hour of bridging and swapping process.
We have to solve this problem, and our North Star is to make the entire Ethereum ecosystem feel like one network. Let’s see how unified liquidity, coupled with wallet upgrades, abstracts bridging and makes the cross-chain layer 2 experience feel like using a single chain.
Why is the currentbridgingso bad? There are some drawbacks here:
You have to visit a separate website, connect the wallet, approve the transfer, transfer it and hope it gets to the other end...
Bridging is usually required It takes 5 to 30 minutes to complete, which is far too slow. Less than 10 seconds is achievable and ideal.
Mostbridgesrequire liquidity to be locked on both networks. The more layer 2 networks we have, the thinner the liquidity will be. Lack of liquidity makes it difficult to move large amounts of funds between chains, and results in lower prices.
Only certain liquid tokens can be bridged, for most networks this is ETH + stablecoins.
There is also an encapsulated Token bridge that does not require locking liquidity. It can support any Token. However, after bridging, you get a non-native version of the token you need, which must be exchanged with the real token to use any application on the new network, which requires liquidity, so we end up in the same predicament.
The bottom line is, if bridgingdoesn’t really need to be done, why are we collectively wasting millions of hours doing it? ?
When you use a decentralized exchange or borrowing protocol, it should track your transactions on all chains Token. When you deposit a token from another chain, it should automatically bridge it to the correct chain in the background, making the entire process feel exactly like the Ethereum mainnet.
Apps and wallets want to achieve this, but the underlying infrastructure is not good enough yet. If thebridgingprocess takes 10 minutes and you lose 1% of your tokens in the process, most users will be dissatisfied with the experience.
Let’s dive into the infrastructure layer and see how to solve this problem.
How liquidity flows seamlessly
In the L2 network, liquidity can be unified in the following 3 main ways, and there is an enhanced way to Increase their speed. These approaches have different trade-offs but complement each other.
They are:
1) Shared Ecology Bridge : Achieve the entire ecosystem chain seamless aggregation of liquidity.
2) Minting/Destroying Token: Can be transferred between any supported chains with unlimited size.
3) LocalBridgeMutual Trust:Enable seamless aggregation of liquidity across ecosystems.
Shared EcosystemBridging
When you bridge from the Ethereum mainnet to any second layer network, the process goes something like this :
Each bridge It's all a smart contract on Ethereum, which we call "local bridge". Whenyou bridge to the second layer network, your assets will be locked on L1 and a copy minted on L2. These networks have the right to mint unlimited amounts of any asset supported by their native bridge.
Although they have the same name and are explicitly not called wrapped assets, every asset bridged from Ethereum to any L2 via the chain's native bridge is actually a wrapped asset , because the contract address and sometimes even the code are different. On Ethereum, USDC’s contract address starts with 0xa0b8, while on Arbitrum it starts with 0xaf88, on Optimism it starts with 0x0b2c, and on Polygon zkEVM it starts with 0xa8ce.
The assets all look and feel the same because the wallet and app have an official asset list with official images for display, so users will never know the difference.
What if instead of having a bridge for each L2, they shared a bridge? Assets can be minted on a shared chain called the interop layer, which then mints them on their final destination, L2.
Polygon Call this new design a “converged blockchain.”
What is the use of this design? In this ecosystem, when moving assets from one chain to another, such as from Polygon zkEVM to OKX X1, there is no need to go through a traditional bridge or bridge back to Ethereum first. Instead, you can destroy the asset and have the interop layer mint the same amount of that asset on the target chain!
Pass Every asset that this interop layerbridgesis now identical on every chain in the ecosystem. Assuming the interop layer is free and fast (Polygon says theirs will be done in <20 seconds), you'll be able to transfer unlimited sizes between any L2 in the ecosystem for free in seconds. Bridging assets!
Both Polygon and zkSync are developing this interop layer design for their ecosystems, and judging from Optimism's design documents, they appear to be pursuing this design as well, although this has not yet been confirmed.
The disadvantage is that it only applies to one ecosystem and requires all chains to use a bridge which increases the risk, but in the ecosystem The rewards in the system of having liquidity flow seamlessly across all chains far outweigh this disadvantage.
Because all tokens are interchangeable between ecosystems, your wallet does not need to show which chain you are on or separate tokens by chain. Instead, your wallet can look like this:
A unified wallet on a unified chain
Execute transactions across multiple chains At this time, your wallet can simply show that you are using the "Polygon" network and perform all bridging operations automatically in the background.
If this design is so good, why wasn’t it implemented earlier? TZKproved that until recently it was fast and cheap enough to make this possible. The Interop layer uses ZK proofs for all mint/destroy operations, so it can be completed in seconds without any challenge period.
Advantages:
-Fast, simple, standard way to transfer Tokens between chains
-Any number can be moved Token, no slippage
-Possibly completely free to use
Disadvantages:
-Only works within a single ecosystem< /p>
-A bridge is a single point of failure/target of attack for the entire ecosystem
-Must be designed from the beginning and cannot be significantly changed within the existing ecosystem
Unlike relying on shared ecological bridging, the chain can leave bridging to Token. Token needs to implement the minting/destroy function and allow users to destroy the token at any time and mint it on another chain.
Move DAI from zkSync to Polygon without using Ethereum mainnet
Move
strong>DAIMoving from zkSync to Polygon without using the Ethereum mainnet can be done through a network such as Layer Zero or Chainlink CCIP The middleware of the class sends these cast/destroy messages. Layer Zero is developing a project called Omnichain that will allow tokens to achieve this functionality.
Some Tokens have already implemented this system. Circle recently launched theirCross-ChainTransfer Protocol (CCTP), which does exactly this for USDC between 8 different networks.
Since USDC has high liquidity on many networks and has no cap on liquidity availability, it could be the perfect bridge to move assets between chains. The wallet can exchange the token you want to bridge to for USDC, use CCTP to bridge that USDC, and then exchange it back to the token you want on the target chain. This can be done automatically by the wallet and with minimal fees or slippage.
The disadvantage of leaving liquidity unified to tokens is that it is up to individual tokens to implement it, and wallets and applications must know which tokens can automaticallybridgeWhat doesn’t work?
This also requires the token to wait for the chain to be finalized before the token can be sent, which can take anywhere from minutes to hours, depending on how often data is written to Ethereum. If the Token does not wait for finalization, it may be doubled, that is, minted on the target chain, and then revoked in a reorganization on the sending chain.
Another risk to consider is that the security of the token relies on the security of each chain andrelaysystem. If an L2 is attacked, it may mint new tokens by sending malicious messages to other chains (e.g., claiming that it destroyed a token when it actually did not). The same situation may occur if the token's relay or oracle is attacked. This will cause the token to malfunction on all chains.
Achievedcross-chainToken with ICS-20 in the Cosmos ecosystem. It solves the problem of "one chain destroys the tokens on all chains" by tracking the path of the token to the current chain. If Token Still have value because they don't cross chain B. This creates the additional problem of token fungibility that wallets and applications will need to solve, but it is a solution.
Advantages:
-Tokens can be moved freely between any L2 chains
-Any number of Tokens can be moved, No slippage
Disadvantages:
-The chain must be safe, a compromised chain may destroy the Token on all chains
< p>-The wallet must understand the functionality of each individual Token to simplify the user experience-Tokens must wait for finalization before they can be moved, which takes minutes and sometimes hours
L2 chains with ZK bridging can achieve fast and free token transfers by mutually trusting the local bridging of other L2 chains. This can be achieved by a user destroying a token on one chain and then minting the token through the local bridge of the other chain using a proof of destruction.
For example, if Scroll reviewed the Linea bridge and deemed it to be secure (and could not be upgraded to make it unsafe), they could set up a service that monitors the Linea bridge's L1 state root, allowing any Users publish proof of their token destruction on Linea, and this destruction transaction is included in the L1 state root, and tokens of equal value are minted on Scroll.
Move any token between two L2 without using the Ethereum mainnet
chain The process of checking status between each other has a more detailed technical description in this article by Vitalik.
This is similar to bridging back to Ethereum and then to other L2s, but this method saves Expensive L1 gas fees.
The risk now is that these local bridges may not be exactly consistent with the number of tokens minted on L2, which is a core property that has not been broken until now. In the above example, if a user moves $1 million of DAI from Linea to Scroll, then the Scroll bridge will be short of $1 million of DAI. If a user wishes to withdraw a large amount of tokens from the local Scroll bridge, then it is possible There will not be enough Tokens available. Bridges can reconcile these differences by doing batched L1Token transfers between each other, or always maintain two-way trust between them, so even if the Scroll bridge is emptied, the whales can still pass through the Linea bridge Withdraw funds.
Advantages:
-Token can be moved freely between trusted chains
-Can be moved anywhere Number of Tokens, no slippage
Disadvantages:
-If a bridge is compromised, it may compromise all bridges that trust it
-The number of tokens locked by a bridge may differ from the number of tokens minted on its network. This may cause problems when withdrawing funds.
These three methods have good scalability and security properties, but have a shortcoming that will seriously slow down the transfer speed. -- awaiting finalization. Finalizing a block requires the sending network to write its data to Ethereum, which can take up to an hour, and then Ethereum finalizing it again, which can take up to another 15 minutes.
With economic incentives, we can create "soft finality" where a transaction is finalized by a node with more economic value than it is worth. This can be achieved by nodes staking on a service like Eigenlayer, where their stake can be slashed and proof that transactions have been finalized. If the transaction is somehow reverted, then these nodes will be slashed, and this slashing may be used to fill the holes caused by the revert.
The benefit of this is that transactions can be soft-finalized in seconds, greatly speeding up allcross-chainToken transfers speed.
This is what Near is working hard to achieve. Rather than needing proofs of send/destroy to be written to Ethereum L1 and finalized, the proofs are instead written to a NEAR fast finality chain, with finality guaranteed by Eigenlayer's stakers if there is a return Roll or restore and they will be cut. This tweet thread goes into further detail on how it works.
Let’s see how this fast deterministic layer improves all three token transfer methods:
1) The Interop layer is already a fast deterministic layer , managed by ecosystem teams (such as Polygon, zkSync, etc.). It allows transfers within the ecosystem to be completed within seconds.
2) When tokens are minted/destroyed between layers, instead of waiting for the transaction to be finalized on Ethereum, which can take up to 20 minutes, the fast finality layer can prove that the transaction was completed and will not be restored, and the node making the attestation will be slashed, if any. The target chain can then trust this layer to mint the transaction as soon as it attests to it.
3) Likewise, when networks trust each other's bridges, they can resolve token transfers through this fast finality layer, rather than waiting for Ethereum, and can use provers in the same way as token sending.
Advantages:
-Token transfers can be finalized and completed in seconds.
Disadvantages:
- It's not clear how cuts are used to fix holes caused by restores caused by double spending.
-Relies on a secondary chain that is not Ethereum for security.
After implementing these new unified liquidity improvements, what are the steps to make cross-L2 wallets feel like they are using the same chain? The two biggest remaining issues are cross-chain gas and integrating applications with this system.
Cross-ChainGas Sharing
If users are constantly moving between multiple chains, how can they be on all of them? Get Gas to pay for transfers?
This is being addressed through Account Abstraction (also known as EIP-4337) and Payment Hub. A payment center is an address where transaction fees can be requested for you. Some wallets, like Avocado and Ambire, allow you to preload a Gas balance and then use this Gas on any chain, similar to a prepaid debit card.
Another simple solution is Bungee Exchange Refuel, which converts Gas on one chain into a little Gas on another chain. This has a worse UX than Payment Center and leaves users with a little gas on many chains, but is effective for EOA accounts (standard non-smart contract accounts).
App Pay Gas Fees
Payment Center also unlocks the ability for the app itself to run a payment center and pay for all user transactions. This will allow anyone to use applications on their own chain without the need for a bridge. Apps can monetize in other ways, such as selling premium items that require tokens, or having a free demo mode but having to pay for the full experience.
Make it easy for applications to take advantage of unified liquidity
Many applications load user token balances by calling balanceOf on every known ERC-20 , which is a slow process and does not support cross-chain. They basically know nothing about tokens that may be bridged from other networks.
This problem should be solved at the wallet level so that every application does not have to reinvent the wheel to support a multi-chain future. EIP-2256 introduces a standard function that wallets can implement so that all token balances can be loaded at once, although only a single chain is currently supported.
If a wallet is multi-chain aware and knows a way to bridge tokens from one chain to another, it can immediately tell the application that the user has these bridgeable tokens, and when the user interacts with the application When the program interacts, the wallet immediately bridges before performing the interaction. This can use any of the above mechanisms to bridge tokens.
Hopefully now you have a better understanding of how liquidity can flow between L2s more smoothly in the future, and how wallets can leverage these new technologies to get off-chain entirely. tethers, making using Ethereum as easy as it is in 2020 without being burdened with high gas fees!
In an article published by Bankless on December 22, Bankless guest author Viktor Bunin discussed and predicted the future of Ethereum and L2.
JinseFinanceCoinbase, the second largest crypto exchange, has recently launched a testnet for their newest product "Base," an Ethereum layer 2 (L2) network.
BitcoinistEthereum’s layer 2 scaling platforms took center stage in the network’s 2022 chapter.
cryptopotatoThere are currently 38 projects deployed on the Ethereum layer-2 network. More are expected as attention shifts to scalability.
CointelegraphIn this article, we will show what sidechains and L2 solutions are and how they can help with scalability.
FtftxOnce fully deployed, users will be able to conduct private transactions through the popular Tornado Cash mixer on Arbitrum's second layer network.
Cointelegraph