Scan to download
BTC $70,740.69 -2.62%
ETH $2,076.78 -2.43%
BNB $645.12 -1.41%
XRP $1.42 -4.56%
SOL $81.67 -4.53%
TRX $0.2795 -0.47%
DOGE $0.0974 -3.83%
ADA $0.2735 -4.22%
BCH $457.98 -0.19%
LINK $8.64 -2.97%
HYPE $28.98 -1.81%
AAVE $122.61 -3.42%
SUI $0.9138 -6.63%
XLM $0.1605 -4.62%
ZEC $260.31 -8.86%
BTC $70,740.69 -2.62%
ETH $2,076.78 -2.43%
BNB $645.12 -1.41%
XRP $1.42 -4.56%
SOL $81.67 -4.53%
TRX $0.2795 -0.47%
DOGE $0.0974 -3.83%
ADA $0.2735 -4.22%
BCH $457.98 -0.19%
LINK $8.64 -2.97%
HYPE $28.98 -1.81%
AAVE $122.61 -3.42%
SUI $0.9138 -6.63%
XLM $0.1605 -4.62%
ZEC $260.31 -8.86%

The chaotic era of Ethereum has arrived: Will MEV harm the interests of ordinary users?

Summary: The MEV-Geth implementation mechanism has changed the expected transaction ordering rules in the network, which may have caused harm to the interests of users in the ecosystem.
Kai
2021-04-12 17:00:36
Collection
The MEV-Geth implementation mechanism has changed the expected transaction ordering rules in the network, which may have caused harm to the interests of users in the ecosystem.

This article was published on Ethereum Enthusiasts, author: Kai.

Imagine a scenario: users trade on an AMM-type DEX, and regardless of the slippage they set, the transaction will ultimately execute at the worst price they can accept. This could be a terrifying situation for users.

TLDR;

The current MEV-Geth implementation mechanism has altered the expected transaction ordering rules in the network, leading to numerous unsettling public fairness issues and potentially harming the interests of users in the ecosystem.

Native Rules of Ethereum Network Transaction Pool

Currently, in the Ethereum network, if users send transactions natively, these transactions will propagate throughout the peer-to-peer network composed of Ethereum full nodes, and the content of the transactions is completely transparent. This means that any full node in the network can see the content of the vast majority of transactions.

As a result, several situations arise in the Ethereum network that disrupt the expectations and experiences of transaction senders (often regarded as some form of "attack"):

  1. Front-running refers to profiting by placing a specific transaction ahead of the target transaction (the attacked transaction) in the same block, mainly targeting liquidation and arbitrage trades;

  2. Back-running refers to profiting by placing a specific transaction after the target transaction in the same block, typically targeting information input mechanism (Oracle) transactions or large trades;

  3. Sandwich attacks, a combination of the above two forms of attacks, place the target transaction exactly between two specifically constructed transactions to profit. Sandwich attacks significantly broaden the range of potential targets; even an ordinary AMM DEX transaction could become a target. The attacker's first constructed transaction creates greater price volatility, and after the target transaction is executed, the second constructed transaction is executed immediately afterward to exchange back the tokens used to launch the attack for profit.

The targets of the attacks are uncertain. Theoretically, anyone who knows your transaction content could potentially attack you, including dApp project parties, professional attackers, wallets, and mining pools (with no "accountability").

The ease of attack is related to the consensus rules of the network and the generally available infrastructure in the ecosystem (attack difficulty, "responsiveness"); for example, if everyone strictly adheres to the current transaction pool rules and only competes through Gas Price to influence the block producers' transaction ordering (requiring mining pools to adhere to industry self-discipline), then sandwich attacks are relatively difficult to execute.

Currently, miners and mining pools are considered the most likely participants to launch attacks because they can directly determine the execution order of transactions in the blocks they package. This is also the origin of the concept of "MEV" (the profit miners gain from their ability to order transactions); however, in practice, due to the time-sensitive nature of attack opportunities, they may be fleeting, and attackers and mining pools often exhibit a cooperative relationship in profit-sharing.

This background is what makes me uneasy about the phenomenon of MEV-Geth and other forms of mining pools directly engaging in sandwich attacks.

Current MEV-Geth Implementation

image

The current MEV-Geth implementation (as of April 10, 2021) only includes the functionality of a searcher (Inspect) that searches for MEV opportunities in the network, relaying atomic transaction bundles to registered mining pool nodes (Relay), and allowing block producers to jump the queue (MEV-Geth client). It constructs a simple network only between registered mining pools and Relay servers.

MEV-Geth is a specially customized Ethereum node client that runs on the mining pool side, allowing this client to store MEV Bundles distributed by Relay and package these special transactions at the head of the queue in the block.

image

Users can broadcast transaction packages called Bundles using MEV-Geth; a Bundle contains information such as: a list of transactions (indicating the consecutive transactions the sender wishes to put on-chain), arbitrage calculation block height, and minimum and maximum timeout periods. In the block where a single Bundle is on-chain, the sender pays ETH as a commission to the block producer (i.e., the mining pool) through the coinbase transaction (rather than through Gas Price).

In the current MEV-Geth implementation, only one Bundle can exist per block, so the block producer will select the Bundle with the highest coinbase payment to be included in the block.

This current implementation simplifies the difficulty of executing sandwich attacks. On one hand, attackers can explicitly declare the front and back relationships of the sandwich transactions; on the other hand, attackers have no worries, as even if they lose in the on-chain competition with other attackers, their transactions will simply time out and become invalid in the MEV-Relay network without incurring Gas fees.

According to public statements from the Flashbots team, they are developing a solution that allows multiple Bundles to be included in the same block, and we may soon see blocks filled with numerous zero Gas fee sandwich attacks.

Finding MEV-Geth Transactions

According to the current implementation, the most notable feature of MEV-Geth transactions is that the Gas Price of both the front and back sandwich transactions is 0.

By opening the block explorer website etherchain.org, you can view the transaction list of any block (this list reflects the execution order of transactions within the block). If a sandwich attack appears at the top of the list and the Gas Price of the sandwich transactions is 0, it is highly likely that this was initiated through an MEV-Geth Bundle.

image

- List head of block at height 12200018 -

image

- The entire process of a transaction being attacked -

The Network Has Fully Deployed MEV-Geth

The current MEV situation can be obtained by querying transactions with 0 gas price and gas used greater than 21000, as detailed in my temporarily established Dune dashboard:

image

From the chart, it can be seen that many mining pools have participated, with over 3500 MEV-related transactions occurring daily, resulting in about a thousand MEV transactions. Assuming an average block time of 12 seconds, there are 7200 (60x60x24/12) blocks per day, meaning that nearly 1/3 of the blocks contain MEV-Geth transactions. Some mining pools have yet to adopt MEV-Geth, and arbitrageurs have not switched to this new competitive model.

Game Theory in Different Environments

We can understand what users gain and lose by comparing several transaction pool operation scenarios.

Public Game State

If the network returns to its native state, and block producers adhere to industry self-discipline, all transactions are public, and anyone can discover unbundled transactions by establishing nodes or using node services; then, if one wishes to sandwich a transaction, they need to send two transactions and set the gas price to ensure the sandwich order before and after the attacked transaction. In a competitive situation, they also need to send multiple copies of the transaction to increase the success rate, and finally, they face the penalty of losing the miner fee if any transaction execution fails.

From the user's perspective, everyone is in an equal and open environment. When they see their transaction being sandwiched or front-run, they have the opportunity and means to accelerate or cancel the transaction to avoid potential losses.

Moreover, the final formed block not only shows the winner of the transaction pool competition but also reflects the actual situation of the transaction pool competition.

Privacy Transaction Services

Here, "privacy transactions" refer to mining pools establishing dedicated channels where transactions entering the mining pool's transaction pool are not broadcast externally but are still sorted and packaged based on Gas Price priority.

When ordinary users use privacy transaction services, their transactions are not publicly disclosed. Therefore, unless the mining pool itself violates confidentiality commitments or participates in attacks, users will not be subjected to the aforementioned attacks.

On the other hand, if attackers use privacy transaction services to attack publicly visible transactions, the attacked parties cannot discover that something is about to happen and cannot respond. However, sandwich attacks are still limited by the randomness of transaction routing and transaction pool sorting, making them difficult to implement.

Furthermore, when multiple parties compete for the same profit opportunity, as long as the mining pool does not disclose the competing transactions, they cannot understand their competitors' bids and can only blindly submit prices into the sorting queue, which indirectly increases the cost and difficulty of attacks.

Additionally, the final formed block can still genuinely reflect the entire situation of the transaction pool competition, allowing external observers to see successes, failures, and their reasons.

If MEV-Geth Becomes Mainstream

After the emergence of MEV-Geth, arbitrageurs and front-runners will submit arbitrageable and sandwichable transactions to this network for bidding, filtering out the Bundle that provides the greatest benefit to the mining pool, which will be prioritized for execution in the next packaged block, ensuring that the bundled transactions achieve a 100% success rate.

Currently, if you also deploy an MEV-Geth node, the Bundle content is transparent to you, so if someone attacks you, you can respond in a timely manner.

But if you do not know what MEV-Geth is, your situation is similar to being attacked by someone using privacy transactions; it becomes worse because the attacker's certainty increases significantly, and the bidding process of the attack cannot be known, as the formed block will only expose the winning transaction and not the competitive process.

Flashbots believes this will bring some benefits to the network: the competitive game process of arbitrageurs is moved to another network, which can alleviate the burden on the Ethereum P2P network; only the winners occupy block space, which can alleviate block congestion. A report has been published on subreddit/EtherMining listing the current additional profit situations in blocks, but it may not necessarily keep pace with the overall revenue reduction caused by declining miner fees in the long term, requiring more long-term data tracking and research.

Decentralization Vision

The original expectation of network consensus was that Ethereum DeFi users and front-runners operated under the same rules, and the competition process and results were transparently exposed in the blocks. With the involvement of mining pools, things have become more complex. Privacy transactions and MEV-Geth have begun to explicitly intervene in upper-level business from the underlying network. MEV-Geth seems to justify sandwich attacks on users with various benefits and allows the bidding process to occur in a network that is not observable from the outside, making the network operation process unfriendly and opaque.

I have a few questions:

  1. Mining pools deploy the current stage of MEV-Geth to gain more benefits for the miners providing computing power, which may be understandable. But does this align with decentralization and the public fairness of the network?

  2. Flashbots previously publicly committed to protecting the openness and decentralization of Ethereum. Is it appropriate to deploy MEV-Geth to the current network before the issues of privacy and public auction competition are resolved?

  3. The superpower derived from the sorting rights of mining pools (miners) may not be removable in a decentralized network, meaning MEV is an objectively existing phenomenon. However, does the emergence of MEV-Geth make the abuse of MEV more convenient, even becoming a legitimate excuse to sandwich user transactions, potentially causing long-term negative impacts?

There is considerable controversy in the community regarding the implementation of MEV or MEV-Geth, with many voices expressing concern:

  • Cornell Professor Ari Juels published "Miners, Front-Running-as-a-Service Is Theft" on CoinDesk.
  • Offchain Labs co-founder Ed Felten published "MEV auctions considered harmful," which is not specifically targeting this issue but opposes the method of auctioning sorting rights for a day. Vitalik has responded to this.
  • A user on the Ethereum Research forum, pmcgoohan, published "MEV Auctions Will Kill Ethereum."
  • Paradigm partner Charlie Noyes also mentioned in "MEV and Me" that "MEV Can Harm Users, MEV Can Harm Ethereum."

If Ethereum wants to become the financial infrastructure platform supporting the entire world, maintaining the security of user assets and the fairness (randomness) of transaction ordering is crucial. All participants compete for packaging queue positions based on miner fee bidding rules, and execution failures will result in the loss of paid miner fees. Mining pools completely ignore transaction content during the packaging process, sorting transactions solely based on miner fees, isolating network validators and application participants from each other, with no interference.

The full deployment of MEV-Geth and the gradual intrusion of miners into the application layer of the Ethereum network make me feel something is amiss. After two days of thinking and researching, I wrote this article in hopes of prompting more people to consider this issue that could have far-reaching impacts on Ethereum. I also thank the friends who helped proofread the content over the past few days, especially Teacher A Jian for constantly questioning the logic and order of the exposition, which made the article more complete and logically sound.

warnning Risk warning
app_icon
ChainCatcher Building the Web3 world with innovations.