EIP-7702 Overview
EIP-7702 is a proposal to add a new Transaction type to allow an EOA to designate a Smart Contract as its "implementation".
The main difference between an EIP-7702 Transaction and other transactions is the inclusion of a "authorization list" property, a set of (chain_id, contract_address, nonce, y_parity, r, s)
tuples that depict what Contract bytecode(s) should be injected onto the Externally Owned Account during execution.
Applications of EIP-7702 include:
- Batching: allowing multiple operations from the same user in one atomic transaction. One common example is an ERC-20 approval followed by spending that approval, a common workflow in DEXes that requires two transactions today. Advanced use cases of batching occasionally involve dependencies: the output of the first operation is part of the input to the second operation. Example
- Sponsorship: account X pays for a transaction on behalf of account Y. Account X could be paid in some other ERC-20 for this service, or it could be an application operator including the transactions of its users for free. Example
- Privilege de-escalation: users can sign sub-keys, and give them specific permissions that are much weaker than global access to the account. For example, you could imagine a permission to spend ERC-20 tokens but not ETH, or to spend up to 1% of total balance per day, or to interact only with a specific application.