Bridging the Gap: The Power of a Unified Mempool

The public mempool is not just an essential element of ERC-4337, but its central cog, turning the entire operation into a positive-sum game.

There are many ways to improve Ethereum accounts. In fact, there have been so many choices that it has hindered the adoption of better accounts and wallets. Without a standard, everyone has created their own account abstraction in one way or another, leading to a largely disparate ecosystem.

A fractured ecosystem

My cofounder Hazim and I were grappling with this disparate ecosystem when we met in early 2021. Each user experience problem we identified stemmed from the limitations of accounts.

The “obvious” solution was smart contract wallets. Despite their long-standing presence and strong followings, smart contract wallets never truly gained popularity. The frequently cited reason was high fees, but that didn't really explain the lack of their adoption on more affordable networks like Polygon or Binance at the time.

We felt there was a deeper reason, so we spent a few months trying to find it. We discovered that, despite the best intentions of these projects, they increasingly transformed into closed ecosystems over time. This seriously hampered their growth.

The technology for creating better accounts on Ethereum was already there, but the real problem was one of system dynamics. Each version of account abstraction could only really address one segment of users. We needed a system that naturally inclined towards openness and interoperability over time, rather than closing up. One that benefits all users.

Luckily, we didn’t have to design it ourselves; ERC-4337 was proposed shortly after we arrived at this conclusion. It was exactly what we were looking for, and we’ve been working with it ever since.

ERC-4337 as a focal point

The strength of ERC-4337 lies in it being a Schelling point, a default solution, for building better accounts on Ethereum.

Creating something similar to ERC-4337 was entirely feasible, and indeed, many did. They are often eager to highlight this fact, and say ERC-4337 isn’t true account abstraction.

To an extent, they are right. ERC-4337 is not the full vision of account abstraction. But that still does not mean that it is not better than what we’ve had before, or that it is just a relayer technology. In any case, focusing on the technology misses the point.

The value of ERC-4337 is that it is a unified call to action, not just a technology.

ERC-4337 required some great technical work, don’t get me wrong. Its architecture is complex but actually quite elegant for what it accomplishes. But I argue its core innovation is that has properties that align it with the natural evolution of the ecosystem, rather than push against it. Here are just a few.

  1. It is compatible with any EVM-compatible chain, so experimentation can be done on many blockchain networks, not just one.
  2. No single entity owns it - the Ethereum Foundation is carrying the torch for core research but there is a wide variety of bundler clients, smart contracts, and paymaster services under development.
  3. The bundler is basically just a lightweight sidecar to validator nodes, so running one to capture order flow or MEV is a no-brainer once volume increases.
  4. It standardizes what metatransactions - or more specifically user operations - should look like and the interactions between smart accounts.
  5. The framework is flexible, so the ecosystem can evolve as we discover what actually works best.

That last point is quite important. As a community we have struggled to adopt the many different native versions of account abstraction. We simply tried to bite off too much at once.

To realize better accounts on Ethereum, and in turn what I believe to be the promise of blockchain technology, we need to build a system with network effects. People need to be rewarded not just for participating, but for getting others to participate.

The canonical mempool is the heart of ERC-4337

I spend a lot of my time promoting ERC-4337, and even Stackup’s competitors, because I know that it only works if we build an open and thriving ecosystem that builds on itself.

This is a textbook example of a positive-sum game. And the flywheel at the core of ERC-4337 is a permissionless transaction pool.

A unified, permissionless mempool means that ERC-4337 is for all users and builders. Not just a segment.

A lot of the research in making ERC-4337 work was in designing the rules for participating in this mempool. The issue is that permissionless networks are susceptible to Denial-of-Service attacks. ERC-4337’s design ensures that there is always a pool of bundlers willing to serve user operations for a profit, effectively creating a safe environment where bundlers can operate effectively and profitably.

The work done by the Ethereum Foundation on ERC-4337 is quite good, especially that of Yoav Weiss and Dror Tirosh. I recommend reading Yoav’s article about the design of the unified ERC-4337 mempool.

A key strategy is to limit the amount of work a bundler has to do when validating a user operation, and preventing non-deterministic behavior during validation. This is done by separating validation from execution, limiting the gas used during validation, banning certain opcodes during validation, and limiting storage access during validation.

Censorship resistance

If you’d like to learn more you can read the standard directly. In short, these measures ensure that malicious actors cannot flood the network with valid operations and then invalidate them cheaply, causing an overload of unpaid work by bundlers and censoring transactions.

Even when bundlers are pressured to censor specific transactions, the network’s permissionless nature incentivizes anyone to launch a new bundler to seize the profits of censored transactions, thereby making the network anti-fragile and more resilient to attacks.

All bundlers are all incentivized to participate in the canonical public mempool and agree to operate under the same restrictions. If different bundlers propagate invalid transactions, they will be blacklisted to avoid a bad actor from flooding the network with operations that have different validity results in different bundlers.

With proper measures to protect the public mempool, ERC-4337 is actually strengthened by the possibility of alternative mempools. Bundlers can collaborate to adopt other mempools that follow more relaxed rules for certain trusted contracts. Bundlers are still incentivized to monitor and include user operation from the public mempool, so these alternative mempools only strengthen its value proposition.

A positive sum game

The canonical mempool is not just an essential element of ERC-4337, but its central cog, turning the entire operation into a positive-sum game.

Through carefully designed and implemented safeguards, the architecture manages to circumvent the common vulnerabilities of permissionless networks. The adaptability and openness of the system, coupled with the introduction of alternative mempools, further bolster the robustness and resilience of the network.