For educational purposes only; not investment advice. Investing may result in loss.
Direct answer
Account abstraction makes an account’s authorization and execution rules programmable. On Ethereum, ERC-4337 implements this without changing the consensus transaction type: a wallet sends a UserOperation through dedicated RPC infrastructure, a bundler wraps one or more operations in a normal transaction to a versioned EntryPoint, and the smart account validates and executes its own operation. Recovery, passkeys, session keys, spending limits, batching, and fee sponsorship are account or service features built on that flow, not automatic ERC-4337 guarantees.
This is distinct from ERC-1271, which standardizes how a contract validates a signature on a message, and EIP-7702, which lets an externally owned account (EOA) delegate execution to code. These mechanisms can interoperate, but they do not share one interface, nonce, deployment, or security model. Account abstraction does not eliminate credentials, gas costs, contract risk, or the need to verify the exact chain and implementation.
Seven-step ERC-4337 flow
- Pin the environment:
chainId, smart-account implementation and upgrade controls, factory, EntryPoint version, address and deployed code hash, bundler support, and whether the chain activates EIP-7702. An address valid for one EntryPoint release or chain is not a universal constant. - Build the version-matched operation. Current logical fields include
sender,nonce,factory,factoryData,callData,callGasLimit,verificationGasLimit,preVerificationGas,maxFeePerGas,maxPriorityFeePerGas, optional paymaster fields, andsignature. On-chain, EntryPoint receives a packed representation; target calls are encoded inside account-definedcallDatarather than a universal target field. - Bind authorization to the correct domain. The
userOpHashcovers the operation except its signature and binds the EntryPoint and chain, preventing reuse across those domains. The account’svalidateUserOpchecks its owner, multisignature, passkey, session, or other policy. ERC-1271isValidSignatureis a separate contract-signature interface; an optional aggregator can validate aggregated signatures. An EIP-7702 authorization tuple is supplied separately from the UserOperation. - Prove fee capacity. The account can prefund through its EntryPoint balance, or a paymaster can conditionally accept liability from its own deposit. A paymaster may sponsor the user, charge a token, enforce allowlists or quotas, and run
postOp; none of those commercial rules is fixed by ERC-4337. Stake and deposit are different: stake supports validation and reputation rules, while deposit pays gas. - Estimate and submit through ERC-7769 RPC. A bundler validates on receipt, again before selection, and again at bundle construction. ERC-7562 restricts validation-stage opcodes and storage access and supports reputation controls against denial-of-service behavior. This simulation checks admission and fee safety; separate full-call simulation is needed to forecast business execution.
- The bundler calls
handleOps. EntryPoint performs any permitted deployment, account and paymaster validation, prefund checks, and optional aggregation before execution. A failed validation prevents that operation from executing. A target call can still revert after valid admission and consume gas. Whether calls inside one account batch revert atomically or permit partial success is defined by the account’s execution code. - Reconcile receipts and state. Match the UserOperation receipt, underlying bundle transaction, EntryPoint events, account deployment, target events, actual gas, token charge, refund, and final balances. Then monitor nonce lanes, owner and recovery changes, session-key revocation, modules, implementation upgrades, bundler and paymaster alternatives, reorgs, and migration or EIP-7702 redelegation.
Four worked examples
- Simplified gas envelope. An operation budgets
120,000execution gas,90,000account-verification gas,45,000paymaster-verification gas,40,000pre-verification gas, and30,000paymaster post-operation gas:120,000 + 90,000 + 45,000 + 40,000 + 30,000 = 325,000 gas. AtmaxFeePerGas = 30 gwei, the simplified cap is325,000 × 30 gwei = 0.009750 ETH. If actual chargeable use is210,000 gasat22 gwei, cost is0.004620 ETH. EntryPoint-version rules, unused-gas penalties, L1 data fees, and rollup pricing can add or reclassify amounts, so this is a budget ledger, not a universal prefund formula. - Parallel nonce lane. With a
192-bit keyand64-bit sequence, key7and sequence42encodenonce = (7 << 64) | 42 = 129127208515966861354 = 0x7000000000000002a. After successful inclusion, that lane expects sequence43; replaying42fails. A different key can have an independent sequence, subject to the account logic and bundler rules. - Paymaster capacity. A paymaster has
0.50 ETHdeposited and each accepted operation needs a maximum guarantee of0.03 ETH. It can coverfloor(0.50 / 0.03) = 16such operations, reserving0.48 ETHand leaving0.02 ETH. A seventeenth operation needs more deposit or a smaller guarantee. Paymaster stake cannot replace this fee deposit. - Execution revert after admission. An operation reserves up to
0.0060 ETH; validation succeeds, but the target execution reverts after consuming180,000 gas × 25 gwei = 0.0045 ETH. The target state changes revert, yet the account or paymaster still owes0.0045 ETH; the unused0.0015 ETHremains subject to the applicable settlement and penalty rules. A successful bundler simulation therefore does not promise business success, inclusion, or finality.
Risks and controls
- Wrong chain, EntryPoint address, release, or deployed code hash can invalidate or misroute an operation.
- A signature missing chain or EntryPoint domain binding can enable replay.
- Factory, counterfactual address, initialization data, or deployment salt can be substituted or miscomputed.
- EIP-7702 delegation can point an EOA at malicious or vulnerable code with broad account authority.
- Initialization front-running or repeat initialization can seize or corrupt an account.
- Proxy upgrades or EIP-7702 redelegation can collide with existing storage layout.
- A compromised upgrade administrator or module manager can replace account behavior.
- Owner, multisignature, passkey, or ERC-1271 validation bugs can authorize theft or lock funds.
- Recovery thresholds, delays, guardians, and cancellation paths can fail or be captured.
- Session keys can exceed intended target, token, amount, duration, or function scope.
- Nonce lanes can collide, gap, replay, or block dependent operations.
- Aggregator outage or signature-aggregation defects can strand otherwise valid operations.
- Bundlers can censor, go offline, apply different local policy, or reject alternative-mempool rules.
- Public UserOperation flow can expose intent to front-running, correlation, and MEV.
- Validation can pass before state changes make the operation invalid at bundle construction.
- Paymaster policy can reject service, its deposit can deplete, or
postOpcan fail. - Token-denominated gas charges can include exchange-rate risk, allowance risk, spread, and service markup.
- Underestimated gas can revert; excessive limits can increase reservation or penalty exposure.
- Account batch semantics can permit partial success when the user expected atomic rollback.
- Target-protocol bugs, hostile front ends, chain reorgs, and weak finality remain outside account abstraction.
Common misconceptions
- “Account abstraction removes private keys.” It changes programmable credential policy; some credential must still authorize actions.
- “A paymaster makes gas free.” Native gas is still paid, and the user, sponsor, or service ultimately bears the cost.
- “Bundler simulation guarantees success.” Admission simulation does not guarantee execution, inclusion, or finality.
- “ERC-1271, ERC-4337, and EIP-7702 are the same interface.” They solve different signature, transaction-flow, and delegation problems.
- “Every chain, wallet, and EntryPoint is compatible and safer.” Support, versions, deployments, code, modules, and controls must be verified separately.
Related topics
Sources
- ERC-4337: Account Abstraction Using Alt Mempool
- ERC-7562: Account Abstraction Validation Scope Rules
- ERC-7769: JSON-RPC API for ERC-4337
- ERC-1271: Standard Signature Validation Method for Contracts
- EIP-7702: Set Code for EOAs
- The EntryPoint Contract
- Simulation Requirements
- Releases - eth-infinitism/account-abstraction