Source: MetaCat EIP-3074 was approved to go live in the next Ethereum hard fork (Prague). This EIP will forever change the way users interact on the EVM chain, making the wallet user experience simpler, cheaper, and more powerful. Here is an overview of EIP-3074 and how it will change the rules of the game: The TLDR of 3074 is that it
gives EOA (ordinary wallet) smart contract functions (such as account abstraction). This includes: the ability to do single transaction approval, batch transactions, wallet asset recovery, sponsored transactions (sponsored txs), etc. Let's first talk about the current wallet problem.
Below is a list of wallet UX issues that can be solved with a smart contract wallet, but this will force users to migrate their wallets, which will result in a bad user experience and cost gas.
This is obviously not the best solution.
So how do we turn an existing EOA wallet into a smart contract wallet?
By adding two new opcodes (computer instructions): AUTH and AUTHCALL. These two opcodes work together to allow smart contracts to act on behalf of EOA. Here is a quick overview of how they work (skip if not interested).
AUTH takes the user's signature and intended action and verifies that their signature is correct. It sets a variable to account for the origin address of the txn.
AUTHCALL then calls the target contract using the initiator address as the caller instead of the actual msg.sender.
This is how EIP-3074 works:
- The user signs a message (off-chain, not a transaction)
- The user or initiator sends the message as a transaction to the caller contract
- The caller uses AUTH and AUTHCALL to verify and call each target contract with the user's address as the sender.
We got a few unlocks from this new transaction flow.
Unlock #1 is the ability to sponsor transactions (sponsored tx). Assume Bob doesn't have any ETH in his wallet. Applications can provide gas for Bob's transactions without Bob having to buy/bridge ETH. The significance of this could be huge in getting micropayments to mass adoption.
Unlock #2 is the ability to perform multiple operations in a single transaction. Right now, in order to swap tokens on Uniswap, you have to first approve Uniswap to use your tokens and then run the actual swap. The user experience is not very good. With EIP-3074, these two operations can be compressed into a single transaction.
Unlock #3 is asset recovery. A special Invoker contract can be set up so that you can use social recovery to recover assets when you lose your private key. If the social recovery conditions are met, you can submit a signature to the Invoker to transfer the assets.
We should recognize that EIP-3074 has several shortcomings.
The biggest one is about Invokers, which need to be fully audited, non-upgradeable, and trustless, otherwise users' funds can be easily stolen.
In addition, some existing reentrancy checks may not apply to EIP-3074.
Because EIP-3074 adds two new opcodes, a hard fork is required to add this change. This is part of the reason why EIP-3074 was delayed and ERC-4337 was adopted first. ERC-4337 (account abstraction) does not require a hard fork and is purely a change to the contract and off-chain system.
Today (April 12, 2024) the core development execution is summarized as follows:
- EIP-3074 will be included in the Ethereum Pectra hard fork.
A big thank you to @lightclients, one of the authors of EIP-3074, who has been pushing this EIP for many years.
To learn more about EIP-3074, you can find the full EIP here:
https://eips.ethereum.org/EIPS/eip-3074
Also, this talk from @lightclients is very in-depth and can help us better understand EIP-3074:
https://www.youtube.com/watch?v=AffftIs6XFE
In summary: EIP-3074 will simplify, secure on-chain interactions and reduce gas fees. The EVM is about to launch two new opcodes that will enhance the capabilities of EOAs and make them almost smart contract wallets.