What is EIP-7702?
EIP-7702 is an Ethereum Improvement Proposal that introduces a new transaction type allowing externally-owned accounts (EOAs) to temporarily act as smart contracts for the duration of a single transaction. During the execution of this transaction, an EOA can have smart contract code, enabling it to function like a smart wallet. After the transaction is completed, the EOA reverts to its original state with no code attached.
Key Features
- Temporary Smart Contract Functionality: EOAs can be "upgraded" to act as smart contracts for one transaction, enabling advanced features like multi-factor authentication, programmable spending, and more, without permanently converting the account.
- Improved User Experience: This proposal brings the convenience and flexibility of account abstraction to all users, making it easier to implement features that were previously only possible with smart contract wallets.
- Forward Compatibility: EIP-7702 is designed to be compatible with Ethereum’s long-term goals for smart account infrastructure and account abstraction, helping to unify the user experience and avoid ecosystem fragmentation.
How It Works
- The EOA user wallet signs the
contract_code and includes the signature in the transaction.
- Upon validation, the
contract_code is temporarily stored in the EOA, allowing it to act as a smart contract for that transaction.
- After execution, the code is removed, and the EOA returns to its standard state.
Significance
EIP-7702 is a major step toward Ethereum’s vision of native account abstraction, improving onboarding and user experience by making advanced wallet features accessible to all users, not just those using smart contract wallets.