Author: @菠菜菠菜, Buidler DAO

 

As the entrance and pass to the crypto world, wallets have an irreplaceable position in the entire crypto industry. Using a wallet is an inevitable part of anyone who wants to enter the crypto world. The function of the wallet has also evolved from the initial pure accounting function to today's multi-chain and multi-scenario usage function.

However, the current threshold for using wallets is too high for new users to learn. This threshold keeps many people who want to enter the crypto world out. Lowering the threshold for wallets can bring more fresh blood and an explosion of ecology to the entire crypto world. With the arrival of the EIP-4337 account abstraction proposal, will the lowered threshold brought by the account abstraction wallet allow wallets to enter the next era and trigger a user explosion in the crypto world?

 

TL;DR

 

▪ The knowledge threshold of the crypto world is high. People generally lack knowledge of blockchain and wallets. The current experience of using wallets is complicated. There are many factors that hinder the joining of new users.

▪ At this stage, novice users will encounter some pain points when using wallets: they must first pay gas fees to use wallets, need to find channels to purchase encrypted assets, dazzling main network choices, and wallet security issues

▪ There are two different types of accounts on Ethereum wallets, namely EOA Externally Owned Accounts and CA Contract Accounts. EOA Externally Owned Accounts refer to wallets controlled by a private key and a public key pair and do not have programmable functions. CA Contract Accounts refer to wallets that exist in the form of smart contracts. Contract Accounts are not controlled by private keys and do not have private keys. Instead, they implement various functions by writing code, but cannot actively initiate transactions.

▪ The two wallet account types have their own advantages, disadvantages and limitations. EOA externally owned accounts can only be generated according to the method of generating key pairs specified by Ethereum. They are not programmable and require gas fees to operate. If the private key is lost, it cannot be recovered. However, compared with the CA contract account type, although the CA contract account type can customize logic to achieve more functional possibilities, the CA contract account type cannot actively initiate transactions and needs to be called by an EOA externally owned account. In addition, generating a CA contract account type wallet requires additional costs. Currently, these two wallet account types cannot solve the problem of complex wallet usage experience.

▪ Account Abstraction is a wallet technology solution to be implemented on Ethereum. Its ultimate vision is to allow the AA account abstraction wallet to combine the characteristics of the two account types, EOA externally owned accounts and CA contract accounts, so that they can be combined into one to replace EOA as the main account. In addition to having the programmability of CA, it can also get rid of the dependence of EOA to actively initiate transactions.

▪ The EIP-4337 proposal extracts the [transaction verification mechanism] that is hard-coded in the consensus layer of the original Ethereum wallet transaction process and hands it over to the new mechanism of EIP-4337. The emergence of the new mechanism enables the account abstract wallet to customize the signature method and brings more application scenarios

▪ Wallet applications that implement account abstraction allow users to use specific signature methods to initiate transactions as the main account without having to own EOA, decoupling the ownership and signature rights of the account abstraction wallet. The EOA owner account of the account abstraction wallet only exists as an owner and does not affect the use of the actual account abstraction wallet

▪ The reason why EIP-4337 was chosen by Ethereum as the final solution is that EIP-4337 can achieve account abstraction without modifying the consensus protocol layer, which avoids the huge consensus layer modification similar to the conversion from POW proof-of-work mechanism to POS proof-of-stake mechanism.

▪ In EIP-4337, the account abstract wallet delegates the [signature verification mechanism] to the entry point contract, which allows the account abstract wallet to use a signature mechanism of any signature form. Wallet developers can choose the signature form for the corresponding scenario to develop wallet products.

▪ The current account abstraction wallet is more like a new standard for smart contract wallets, and it cannot get rid of the reliance on EOA as the wallet owner. And the current account abstraction proposal still has some shortcomings and risks: smart contract risks, higher GAS, technical implementation issues

 

Currently, the new users

What are the pain points of using a wallet?

 

Due to the high knowledge threshold of the crypto world, people generally lack knowledge about blockchain and wallets. The current experience of using wallets is complicated, and there are many factors that hinder the joining of new users.

Pain point 1: You must pay Gas fee before using the wallet

When a novice user is looking forward to experiencing the world of crypto and downloads a wallet to get started, he is surprised to find that the wallet cannot be used because there is no public chain native token (such as Ethereum's ETH) as Gas fee in the wallet. The wallet cannot perform any operations because every on-chain operation of the wallet requires miners to package the operation and pay Gas fees to the miners as labor fees. At this time, the novice has to start looking for channels to purchase encrypted assets, but many wallet products do not provide deposit and withdrawal channels. Most novices may choose centralized exchanges.

Pain point 2: Crypto asset purchase channels and dazzling mainnet choices

When novice users want to purchase crypto assets, they may choose wallet products with deposit and withdrawal channels, centralized exchanges, over-the-counter transactions and other channels to purchase crypto assets. However, for novice users who choose centralized exchanges and over-the-counter transactions, if they want to transfer assets to their wallets after purchasing them on centralized exchanges, novice users will be confused by the various main networks for transfer. Learning how to choose a main network requires a certain learning cost. If you are not careful, transferring to the wrong network will be extremely cumbersome to handle. If it is an over-the-counter transaction, it is very risky. Novice users are very likely to become the target of scammers.

Pain point 3: Wallet security issues

For novice users, even if they finally get the gas fee fixed and can use the wallet to interact, the entire crypto world is a dark forest for them. Novice users need to learn cryptographic knowledge about wallets, such as private keys and public keys, and also need to understand what private keys are and think about how to ensure the security of private keys and guard against scams in the crypto dark forest. These are costly to learn and easy to be deceived for novice users. The most important thing is that once the private key is lost or forgotten, it cannot be retrieved, and it cannot be retrieved like retrieving a password in a Web2 application. This is difficult for Web2 users to get used to.

 

What types of Ethereum wallets are available?

 

Currently, there are two different types of accounts in Ethereum wallets, namely EOA Externally Owned Accounts and CA Contract Accounts.

  • EOA Externally Owned Accounts

    EOA externally owned account type wallets are wallets controlled by a private key and a public key pair. The functions of externally owned wallets are basically only to receive, hold, send tokens and interact with smart contracts. They do not have programmable functions, and gas fees are required for each transaction. There is no cost to create an externally owned account type wallet, but it can only be created by generating a private key.

  • CA Contract Account

    A wallet of the CA contract account type refers to a wallet that exists in the form of a smart contract. The wallet of the contract account type itself is not controlled by a private key and does not have a private key. Instead, it implements various functions by writing code, such as DeFi protocol, multi-signature wallet, safe, faucet, etc. Common uses include multi-signature wallets, that is, wallets that require multiple external account wallets to authorize transactions, usually used for corporate wallet management. Creating a contract account wallet requires consuming gas fees. The contract account wallet itself cannot actively initiate transactions, but requires external account wallets to call and pay gas fees to passively initiate transactions.

These two wallet account types have their own advantages, disadvantages and limitations. EOA externally owned accounts can only be generated according to the method of generating key pairs specified by Ethereum. They are not programmable and require gas fees to operate. If the private key is lost, it cannot be recovered. However, compared with the CA contract account type, although the CA contract account type can customize logic to achieve more functional possibilities, the CA contract account type cannot actively initiate transactions and needs to be called by an EOA externally owned account. In addition, generating a CA contract account type wallet requires additional costs. These two wallet account types currently cannot solve the problem of complex wallet usage experience.

 

What is account abstraction?

What are the advantages of EIP-4337 account abstraction?

 

Account Abstraction is a wallet technology solution to be implemented on Ethereum. Its ultimate vision is to allow the AA account abstraction wallet to combine the characteristics of the two account types, EOA external accounts and CA contract accounts, so that they can be combined into one to replace EOA as the main account. In addition to having the programmability of CA, it can also get rid of the dependence of EOA to actively initiate transactions.

The Account Abstraction discussed here refers to the Ethereum EIP-4337 proposal proposed by Vitalik. This proposal extracts the [transaction verification mechanism] that is hard-coded in the consensus layer of the original Ethereum wallet transaction process and hands it over to the new mechanism of EIP-4337. The emergence of the new mechanism enables the account abstraction wallet to customize the signing method, and brings more application scenarios such as: payment of Gas, aggregate signature, privacy protection, etc.

After the implementation of the EIP-4337 proposal, the account abstraction wallet is not limited to the signing method of the Ethereum Elliptic Curve Digital Signature Algorithm (ECDSA) key pair used by the EOA external account type wallet. Wallet application developers can apply any type of signature scheme to the account abstraction wallet application so that users can use other signature methods to initiate transactions, thereby lowering the user's usage threshold.

Wallet applications that implement account abstraction allow users to use specific signature methods to initiate transactions as the main account without having to own EOA, decoupling the ownership and signature rights of the account abstraction wallet. The EOA owner account of the account abstraction wallet only exists as an owner and does not affect the use of the actual account abstraction wallet. The decoupling of ownership and signature rights allows wallet products to provide users with social recovery and other means, so that people do not have to worry about not being able to retrieve their private keys even if they lose them.

Due to the scalability brought by the new mechanism of account abstraction wallet, the pain point of having to have Gas before using the wallet can also be solved. Account abstraction wallet can not only allow third parties to pay for Gas, but also realize the payment of Gas fees with assets other than native tokens. This will greatly reduce the threshold for novice users to use Gas fees. It seems foreseeable that in the near future, the lower threshold brought by account abstraction and more customized functions may lead to a new era of wallets.

 

Why Ethereum chose

EIP-4337 Account Abstraction Proposal?

 

The discussion on account abstraction has never stopped since the launch of Ethereum. From the earliest EIP-101 to EIP-3074 and now the latest EIP-4337, the account abstraction solution has gone through several versions, but most of the solutions were immature and the modifications to the consensus protocol layer were too complicated and were eventually shelved.

After a long discussion and iteration from 2015 to the present, Ethereum finally chose between EIP-3074 and EIP-4337. If EIP-4337 allows CA smart contract account wallets to be used like EOA, then EIP-3074 allows EOA external account wallets to have programmable functions of smart contract accounts. Finally, with the latest Ethereum roadmap announced by Ethereum founder Vitalik, EIP-4337 was officially included in the implementation of The Splurge phase, which also made EIP-4337 the final solution for account abstraction.

The reason why EIP-4337 was chosen by Ethereum as the final solution is, first of all, because EIP-4337 does not require modifications to the consensus protocol layer to achieve account abstraction, which avoids the huge consensus layer modification that is no less than the conversion from the POW proof-of-work mechanism to the POS proof-of-stake mechanism. EIP-3074 involves changes to the consensus layer, and once a problem occurs, a hard fork is required to solve the problem. Secondly, because EIP-3074 allows accounts outside EOA to own smart contract accounts, the signature mechanism still uses a fixed ECDSA signature, and it cannot use any signature method like EIP-4337. Therefore, compared with EIP-3074, EIP-4337 seems to have more advantages in lowering the wallet threshold.

Image source: ethereum.cn translation

 

How does the EIP-4337 account abstraction wallet work?

How is it different from other wallet account types?

 

Account abstraction introduces some new roles and mechanisms compared to previous account types:

Wallet Contract: A wallet smart contract after account abstraction, which can implement custom wallet logic.

Entry Point Contract: A contract that communicates and coordinates with the wallet contract and is responsible for handling verification and executing user operations.

User Operations (uo): A new form of off-chain transaction initiated by users, different from the previous [Transaction, tx].

Bundler: An off-chain computing node responsible for packaging user operations and passing them to the entry point contract.

User Operation Mempool: A memory pool dedicated to accumulating pending user operations, independent of the transaction memory pool.

Paymaster: An optional third-party payer contract account for Gas payment.

If you don't understand what these new terms are, I will use a simplified flowchart to show you. First, let's understand the transaction mechanism of EOA externally owned account type wallets. EOA externally owned wallets need to sign an ECDSA signature before they can initiate transactions.

Image source: https://medium.com/nethermind-eth/ethereum-wallets-today-and-tomorrow-eip-3074-vs-erc-4337-a7732b81efc8

From the figure, we can see that the steps for an EOA account type wallet to initiate a transaction are:

  1. The user uses the private key to perform ECDSA signature on the transaction information to generate a transaction with a signature (Transaction, tx)

  2. The signed transaction will be sent to the memory pool for pending transactions.

  3. Miners process transactions in the transaction memory pool and verify validity

  4. If the verification is successful, the transaction will be included in the block, otherwise the transaction will be discarded.

Since there is no unified transaction process standard for CA contract account types, the figure below shows the transaction process of a smart contract wallet that relies on Relayer. We can see that CA contract type accounts need to rely on an EOA external account type wallet to sign an ECDSA signature to execute transactions, and the role of Relayer may be accompanied by centralization risks.

Image source: https://medium.com/nethermind-eth/ethereum-wallets-today-and-tomorrow-eip-3074-vs-erc-4337-a7732b81efc8

From the figure, we can see that the steps for a wallet of a certain CA contract account type to initiate a transaction are:

  1. The user uses the private key to sign the transaction information in any form to generate a signed transaction message (signed message)

  2. The signed transaction information will be sent to the node Relayer responsible for conveying the message

  3. Relayer uses the private key to perform ECDSA signature on the transaction information with the user's signature to form a transaction

  4. Relayer sends the transaction containing the user's transaction information to the user's wallet smart contract through Relayer's EOA external account wallet for execution

  5. The user's smart contract wallet executes the operation and is verified by the miners before being included in the block

Next, let’s look at the wallet transaction mechanism after EIP-4337 account abstraction

Image source: https://medium.com/nethermind-eth/ethereum-wallets-today-and-tomorrow-eip-3074-vs-erc-4337-a7732b81efc8

From the figure, we can see that the steps to initiate a transaction after account abstraction are:

  1. The user initiates a wallet user operation and uses any form of private key to sign the user operation to generate a signed user operation (UserOperations, uo)

  2. User operations with signatures will be sent to the pending user operations memory pool for processing

  3. Bundler packages the user operations in the user operation memory pool into a transaction and submits it to the entry point contract

  4. The entry point contract handles all user actions: verifies the existence of the wallet - requires the wallet to verify the user action - sends the user action to the smart contract wallet for execution

  5. Smart contract wallet executes user operations and incorporates them into blocks

By comparison, we can find that transactions initiated by accounts outside EOA need to rely on Ethereum's fixed ECDSA signature algorithm for signature, and CA contract accounts ultimately need to rely on ECDSA signature algorithms of accounts outside EOA to sign transactions. In EIP-4337, the account abstraction wallet handed over the [signature verification mechanism] to the entry point contract, which allows the account abstraction wallet to use a signature mechanism of any signature form. Wallet developers can choose the signature form of the corresponding scenario to develop wallet products. Users can directly control the account abstraction wallet through the wallet application's specific signature method, and this signature method can be easily used by Web2 users or a customized method for special scenarios.

And since any miner can act as a Bundler, this avoids the centralization risk of the Bundler role. At the same time, Bundler can prevent Flashbot from monitoring the memory pool for MEV arbitrage by bundling transactions. The emergence of these new mechanisms also brings more application scenario imagination space, such as Paymaster, a third party that pays gas fees on behalf of others.

As can be seen from the figure, transactions (tx) and user operations (uo) are two independent memory pools. Due to the existence of the entry point contract of the account abstraction, the paymaster contract can be combined with the entry point contract like Lego blocks. Before the entry point contract verifies the user operation (uo), it first verifies the paymaster: Do you agree to pay? Is there enough ETH to pledge to pay the gas fee?

In addition to full subsidies from the payee, if the user's account contract only has non-gas fee tokens such as USDT, USDC, etc., the user can also transfer other tokens of equal value to the gas to the payee contract to achieve the effect of paying gas fees without ETH.

In addition to paying for Gas, the entry point contract can also be combined with the aggregate signature verification contract to implement the aggregate signature function and control the wallet through multi-person signatures.

From the above cases, we can see that the modular composability of the entry point contract in the EIP-4337 solution brings more application scenario imagination space. It seems that the account abstraction wallet can bring many benefits to the entire crypto world, but is the reality really so beautiful?

 

EIP-4337 Account Abstraction

What are the shortcomings and risks?

 

Although the vision of account abstraction is very beautiful, the reality is often very bleak. The current account abstraction wallet is more like a new standard for smart contract wallets, and it cannot get rid of the reliance on EOA as the wallet owner. And we all understand that the more complex things are, the more likely they are to go wrong. The current account abstraction proposal still has some shortcomings and risks:

Smart Contract Security Issues

Smart contract security has always been a problem that has plagued the crypto world. We can even see that many contracts that have passed the "smart contract audit" often have security vulnerabilities, and every time a contract security problem occurs, it is often accompanied by huge property losses. For the EIP-4337 account abstraction solution, the modular accumulation of account abstraction wallet functions and the addition of new mechanisms will make its code execution logic more complicated, and often more complex code execution logic may be accompanied by potential security risks. Since the account abstraction wallet and the entry point contract are both smart contracts, once there is a problem with the entry point contract or the wallet contract, it may lead to a disastrous hacking incident, and people's trust in the use of account abstraction wallets will be greatly reduced.

Higher gas fees

In addition to potential contract security risks, account abstraction wallets require users to pay higher gas fees, because compared to EOA external accounts and CA contract accounts, account abstraction wallets have more steps to process transactions and the processing logic is more complicated. More operations need to be processed, which means more gas fees are required. Although Vitalik also proposed a solution that can reduce gas consumption by processing account abstraction data through Layer2, this will also take a long time.

Technical implementation issues

There is still a long way to go before EIP-4337 is implemented. Many technologies that can be realized in theory often encounter many difficulties in practice, such as compatibility issues, complex node verification processes, how to prevent Bundler from doing evil, technical logic that cannot be implemented, etc. Solving these technical problems requires a long period of trial and discussion, which is why EIP-4337 was placed in the sixth stage of Ethereum upgrade, Splurge.

The road ahead is long and arduous. The crypto world needs wallets with lower thresholds and greater security to attract more new users and break through the bottleneck of user volume. I believe that with the realization of account abstraction, it will bring a whole new imagination space to the crypto world. There may even be an unexpectedly better alternative to replace account abstraction in the near future. The speed of iteration and update in the crypto industry is far beyond our imagination, which is also the charm of this industry.