Risk Warning: Beware of illegal fundraising in the name of 'virtual currency' and 'blockchain'. — Five departments including the Banking and Insurance Regulatory Commission
Information
Discover
Search
Login
简中
繁中
English
日本語
한국어
ภาษาไทย
Tiếng Việt
BTC
ETH
HTX
SOL
BNB
View Market
Krypital Group: Should we be wary of "MEV"?
Krypital Group金氪
特邀专栏作者
2022-09-08 07:00
This article is about 5300 words, reading the full article takes about 8 minutes
How does MEV come about and what impact will it have on the crypto economy? Where is the future of MEVs?

Author: Asher

Overview:

Overview:

You have found a very good investment opportunity. You open Uniswap, enter the transaction amount, click Confirm, and wait patiently for the transaction to complete.

image description

(The above data: it is a common situation in Dex transactions)

first level title

1. MEV and "Dark Forest"

In 2019, smart contract researcher Phil Daian co-authored with his colleaguesFlash Boys 2.0Miners can extract value"Miners can extract value"The term (MEV) is mainly aimed at the phenomenon of a large number of robot arbitrage transactions in Dex. MEV, namelyMiner extractable value, originally translated as the maximum extractable value of miners, and later found that the maximum extractable value (maximal extractable value) is a more accurate description. In a blockchain network, miners (or "validators") have the final right to package and order transactions (including or excluding certain transactions). Miners (or "verifiers", collectively referred to as block producers hereinafter) use this right to obtain the maximum benefit is called MEV.

image description

(The above figure shows the cause of MEV)

Although the memory pool is invisible to ordinary users, it has become a gathering place for many "secret transactions" in the "code is law" blockchain world. Numerous "arbitrage bots" closely monitor the mempool, looking for profitable deals. In the "sandwich" attack at the beginning of the article, after the arbitrage robot detects your transaction, it initiates a transaction. Through higher gas fees, the transaction is easier to be accepted by block producers and packaged first.

These arbitrage bots are called searchers. Seekers run complex algorithms on blockchain data to detect profitable MEV opportunities and have bots automatically submit these profitable deals to the network. Miners do get a portion of the MEV amount because searchers are willing to pay high gas fees (which belong to miners) in exchange for a higher probability of having their profitable transactions included in blocks early.

Today, the assets locked in DeFi have exceeded 45 billion US dollars, with a maximum of more than 150 billion US dollars. Although smart contracts allow all data to be made public on the chain, most transactions on the chain have to go through a disordered memory pool monitored by many robots and block producers. Thinking about it, it is indeed a bit chilling. In a report by Paradigm in August 2020, it was vividly called Ethereum as a"Dark Forest". However, under the constraints of the infrastructure and the fact that most users do not know much about the code, users want toEscape from this "dark forest"first level title

2. The MEV type—extremely harmful to users, but not all bad

secondary title

1. Front-running trades

Frontrunning transactions are the most common way to extract MEV, and the "sandwich attack" mentioned above is a type of frontrunning transactions.

"Running transactions" also exist in traditional finance, but are subject to strict financial supervision. In the unregulated encrypted world, "front-running" is becoming more and more rampant on the chain, and even gave birth to the "FAAS" (front-running as a service) business. Some research institutions or miners such as Flashbots (an institution that studies MEV, which will be mentioned later) are operating "FAAS" to protect users' transactions by regulating the MEV market.

secondary title

2. Liquidation

For DeFi applications of lending or derivatives, users usually need to pay collateral. As the market fluctuates, the value of the collateral will change. When the value of the collateral falls to the liquidation line, liquidation will be initiated. Different protocols have different liquidation methods. For example, protocols such as Compound, Aave, and dYdX allow liquidators to purchase collateral at a certain discount when the user’s collateral is facing liquidation; there are also some protocols that distribute liquidation fees to liquidators. Searchers will closely monitor Funding of on-chain borrowers.

secondary title

3. Arbitrage

secondary title

4. MEV in the NFT field

MEV also often appears when NFT is hot, for example, a certain NFT has just started to be issued. If a searcher wants one of these NFTs or a set of NFTs, they can program the transaction so that they are the first to buy. Or, if the NFT ismistakenly listed with a low price, searchers can pre-empt other buyers and snap up at a low price.

secondary title

5. Other

MEV also includes time bandit attacks (time-bandit-attack), uncle block bandit attack (Uncle bandit attack), etc., and some new MEVs are in the pipeline.

We see that MEV is not always bad, such as arbitrage in Dex and liquidation in lending protocols. However, it must be admitted that MEV at the application layer has indeed caused great trouble to users. MEV, such as frontrunning and sandwich attacks, makes users on Dex face greater slippage and worse transaction execution, which reduces user experience and causes economic losses to users. Since the essence of MEV is to facilitate transactions through higher Gas prices, it will eventually increase the Gas cost of the network and even cause network congestion.

first level title

3. How to deal with MEV?

image description

(Data source: Flashbots)

secondary title

1.Flashbots

Flashbots is by far the most in-depth understanding and attempt to address the MEV problem. In their view,MEV exists and is reasonable. The final solution is to standardize MEV, democratize MEV, and reduce the externalities of MEV (sandwich attacks, etc.), which makes more sense than eliminating MEV.

Flashbots creates an ETH node for miners that not only monitors the mempool like any other node, but also connects to relayers operated by Flashbots. This MEV-Relay is a parallel channel that links the Seekers together. The searcher robot bundles the transaction and Gas fee that it wants to package, and the miners obtain the right to package the MEV block through bidding.

In this way, Flashbots can increase the revenue of miners, reduce the cost of searchers, and protect user transactions. However, the Flashbots program also faces a lot of controversy. First, Flashbots cannot reduce MEV; second, MEV is essentially a kind of "exploitation" of ordinary users,secondary title

2.Cowswap

Cowswap is a Dex aggregator behind the cooperation of Balancer Labs and Gnosis. It provides users with MEV protection through batch auctions. When two traders each hold an asset the other wants, orders can be settled directly between them without the need for an external market maker or liquidity provider. Cowswap also integrates multiple Dex, so that the excess part of the same transaction can be settled through the best AMM. Trades are sent by specialized "solvers" that set strict slippage boundaries. The solvers compete with each other to achieve the best price for the user.

In addition, there are other solutions, including Mist X in cooperation with Flashbos, private transactions, etc.first level title

4. The "merger" of Ethereum is imminent, and the MEV battlefield enters L2

As expected, Ethereum will complete its “merge” in September. The biggest change brought about by the "merger" is that the block producer has changed from the current miner to the verifier, and there is no longer a block reward, but the Ethereum protocol starts inflation according to the pledge rate of the entire network, and distributes the reward to the verifier .

Verifiers include transaction proposal verifiers and block sorting verifiers, and those who propose successful verifiers will receive additional incentives. This also means that the ETH merger does not eliminate MEV. ** And if the verifier who proposes the transaction can propose a success, the MEV obtained will greatly increase its income.

A bad situation is that people with a large number of validator stakes will propose their blocks with a high probability of success, get more rewards, and then further expand their validator stakes through pledges, and the cycle goes on, eventually controlling the vast majority of validators The winner's node will obtain the vast majority of MEV, resulting in further centralization of Ethereum network nodes.

One solution currently proposed is PBS, which separates block builders from block proposers. The investment institution IOSG has done an in-depth analysis on this:

"The idea of ​​PBS is as follows: Builders build a sorted list of transactions and submit bids to the Proposer. The Proposer only needs to accept the transaction list with the highest bid, and no one can know the transaction until the winner of the auction is selected. specific content. IOSG's

This separation and auction mechanism introduces "involution" between the game and the Builder: After all, each Builder has a different ability to capture MEV, and the Builder needs to weigh the relationship between the potential MEV profit and the auction bid, so that the actual This reduces the net income of MEV; regardless of whether the block submitted by the final Builder can be successfully produced, the bidding fee needs to be paid to the Proposer. In this way, Proposer (in a broad sense, all validator sets, randomly reselected within a certain period of time) is equivalent to sharing a part of MEV's revenue, which weakens the degree of centralization of MEV. "

But what worries me even more is that Ethereum has already decided to use Rollup as a future expansion solution. Whether it is the upcoming proto-danksharing or danksharing, it is to optimize Ethereum as a security layer and consensus layer, and to promote Rollup as an Ethereum The executive layer of the workshop.

We already know that the essence of Rollups is to complete the transaction execution and settlement off the chain, and the ordering of off-chain transactions needs to be done through a sequencer, and the sequencers of the current mainstream L2 solutions are centralized or Decentralized.

Submitting the final sorting to a centralized verification mechanism, if MEV's income is large enough, may lead to the worst situation - block reorganization. It's not impossible,Paradigm also expressed the above-mentioned concerns.

Fortunately, we still have time. Both external agencies such as Flashbots and L2 themselves are working hard to solve this problem.

Flabots has set up research specifically to study the MEV problem after ETH "merger".

Optimism proposes the MEV Auction (MEVA), similar to Flashbot's solution. Transactions are conducted through an auction, and the winner of the auction has the right to reorder transactions but cannot delay more than N blocks, otherwise a new sequencer will be selected. This is a solution to embrace MEV. Although it cannot eliminate MEV, it can weaken the rights of sequencers and promote the publicization of MEV.

Arbitrum opposes MEVA, proposing that the sequencer will be controlled by a set of decentralized independent parties, so the verifier will not have any say in the transaction ordering, so MEV will not be generated. Arbitrum expects to launch the solution next year.

Both Starkware and ZkSync have adopted Veedo's solution. During the sorting phase of the transaction, the transaction will be closed through a time lock, and the transaction will be opened after the sorting of the transaction is completed, thereby eliminating MEV.

first level title

5. Where will MEV go in the future?

Although MEV has only entered people's field of vision in recent years, its vast market and huge influence are gradually attracting everyone's attention. As more and more developers and researchers continue to explore, we will see more and better solutions emerge.

Regarding the future of MEV, Hasu, the leader of Flashbot, recently proposed 8 predictions for MEV in a hackathon, including:

1. Technology to reduce MEV will come out on L1;

2. MEV auctions will become the standard for executing transactions;

3. The public memory pool will gradually disappear;

4. The problem of external orders will be highlighted;

5. MEV will be returned to the user;

6. The rise of cross-chain MEV;

7. Delayed auctions will become increasingly important;

8. There will be more MEV solutions at the application layer

videovideo

In my opinion, MEV seems to be a problem of socialization even though it generates a lot of externalities. MEV was born when we chose encryption technology, when we chose blockchain, when we chose a decentralized way to participate in permissionless network activities and financial transactions. As for the problem of socialization, it is not solved by a single solution, but requires the joint participation of all people.

Related references & extended information:

1. dark forest

2. dark forest

3. escape from the dark forest

4. time bandit attack

5. time bandit attack

6. Uncle Block Bandit Attack

7. Flashbots data query

8.Paradigm expression

ETH
Welcome to Join Odaily Official Community