Crypto Training
EIP-4337 Evolution Deep Dive: v0.6 -> v0.7 -> v0.8 -> v0.9
A code-first evolution map of ERC-4337 EntryPoint releases: what changed in each version, why it changed, what new risks were introduced, what audits fixed, and what 'battle-tested' really means in practice.
ERC-4337 has not evolved as a single "finished" design. It has evolved as a living security system under real adversarial pressure.
This post traces that evolution from v0.6.0 to v0.9.0 using:
- local source snapshots for each tagged
eth-infinitism/account-abstractionrelease - official release notes
- ERC text updates
- bundled audit reports (OpenZeppelin + Spearbit)
The goal is not just "what changed". The goal is:
- what changed
- why it changed
- what new risks each change introduced
- what was actually fixed vs what remains operationally risky
Scope and references#
Core code and release references:
- v0.6.0 release: https://github.com/eth-infinitism/account-abstraction/releases/tag/v0.6.0
- v0.7.0 release: https://github.com/eth-infinitism/account-abstraction/releases/tag/v0.7.0
- v0.8.0 release: https://github.com/eth-infinitism/account-abstraction/releases/tag/v0.8.0
- v0.9.0 release: https://github.com/eth-infinitism/account-abstraction/releases/tag/v0.9.0
- ERC-4337 spec: https://eips.ethereum.org/EIPS/eip-4337
- ERC-4337 docs portal: https://docs.erc4337.io/index.html
Helpful ecosystem references:
- viem smart accounts docs: https://viem.sh/account-abstraction/accounts/smart
- ERC-4337 docs paymaster signature page: https://docs.erc4337.io/paymasters/paymaster-signature.html
- ERC-4337 docs simulation requirements: https://docs.erc4337.io/bundlers/simulation-requirements.html
- QuickNode AA guide part 1: https://www.quicknode.com/guides/ethereum-development/wallets/account-abstraction-and-erc-4337
- QuickNode AA guide part 2: https://www.quicknode.com/guides/ethereum-development/wallets/account-abstraction-and-erc-4337-pt-2
- Alchemy overview: https://www.alchemy.com/overviews/what-is-account-abstraction
- Hacken overview: https://hacken.io/discover/erc-4337-account-abstraction/
- Cyfrin glossary: https://www.cyfrin.io/glossary/erc-4337
Primary contract links by version:
- v0.6
EntryPoint.sol: https://github.com/eth-infinitism/account-abstraction/blob/v0.6.0/contracts/core/EntryPoint.sol - v0.7
EntryPoint.sol: https://github.com/eth-infinitism/account-abstraction/blob/v0.7.0/contracts/core/EntryPoint.sol - v0.8
EntryPoint.sol: https://github.com/eth-infinitism/account-abstraction/blob/v0.8.0/contracts/core/EntryPoint.sol - v0.9
EntryPoint.sol: https://github.com/eth-infinitism/account-abstraction/blob/v0.9.0/contracts/core/EntryPoint.sol - v0.9
UserOperationLib.sol: https://github.com/eth-infinitism/account-abstraction/blob/v0.9.0/contracts/core/UserOperationLib.sol - v0.9
Helpers.sol: https://github.com/eth-infinitism/account-abstraction/blob/v0.9.0/contracts/core/Helpers.sol - v0.8
Eip7702Support.sol: https://github.com/eth-infinitism/account-abstraction/blob/v0.8.0/contracts/core/Eip7702Support.sol - v0.9
BasePaymaster.sol: https://github.com/eth-infinitism/account-abstraction/blob/v0.9.0/contracts/core/BasePaymaster.sol
TLDR timeline#
| Version | Release date | Canonical EntryPoint in release notes | Core theme |
|---|---|---|---|
| v0.6.0 | 2023-03-29 | 0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789 | First production generation |
| v0.7.0 | 2024-03-27 | 0x0000000071727de22e5e9d8baf0edac6f37da032 | Gas/accounting refactor + simulation model shift |
| v0.8.0 | 2025-03-26 | 0x4337084d9e255ff0702461cf8895ce9e3b5ff108 | EIP-7702 + EIP-712 hash model |
| v0.9.0 | 2025-11-17 | 0x433709009b8330b5d5a6d4e97c25f2f1f189e4e4 | Paymaster signature + EOF-safe reentrancy model |
Baseline architecture that stayed stable#
Even with major version jumps, the core two-phase execution pattern stayed consistent.
The complexity did not come from changing this shape. Complexity came from tightening every edge case around this shape.
v0.6.0: first production generation#
What was added or stabilized#
Main additions around the v0.6 line included:
- first widely adopted production EntryPoint generation
- aggregator support model stabilized
- nonce validation moved/strengthened in EntryPoint path
- recursive
handleOpsprevention hardening - request hash consistency fixes
Examples from code history and release commits:
AA-159 prevent recursive call into handleOpsAA-161 validate Nonce in EntryPointAA-162 Inconsistent userOpHash
Why those changes were needed#
Because the system moved from concept to production mempool economics:
- malformed nonce handling or hash ambiguity breaks replay safety
- recursive execution paths can become denial primitives
- hash mismatches break signer interoperability and simulation reproducibility
Security findings and fixes in this generation#
From the OpenZeppelin incremental audit (published 2023-02-23):
- client-reported "Detect warm storage accesses" simulation mismatch risk (bundler pays on-chain failure)
- client-reported basefee leakage path
- replay weaknesses in sample verifying paymaster
- self-destruct risk in sample Gnosis manager path
- revert-reason bombing risk in EntryPoint call sites
The report explicitly marked "Revert reason bombing" as only partially resolved at that time.
Risks introduced by this generation#
v0.6 brought production viability, but it also exposed a hard truth:
- the biggest risks are often not direct fund drains
- the biggest risks are bundler-loss and mempool-griefing paths that become DoS multipliers
v0.7.0: accounting and validation architecture rewrite#
This was the most structurally important jump.
Major feature changes#
UserOperation->PackedUserOperationand packed gas fields.paymasterVerificationGasLimitandpaymasterPostOpGasLimitsplit out from one shared verification limit.EntryPointSimulationsseparated from deployed EntryPoint path.- second-paymaster-
postOppath removed. - unused gas penalty logic introduced.
- ERC-165 support and richer revert/error model.
Code references:
- v0.7
PackedUserOperation: https://github.com/eth-infinitism/account-abstraction/blob/v0.7.0/contracts/interfaces/PackedUserOperation.sol - v0.7
EntryPointSimulations: https://github.com/eth-infinitism/account-abstraction/blob/v0.7.0/contracts/core/EntryPointSimulations.sol
Why these changes happened#
Two main reasons:
- gas accounting correctness under adversarial limits
- reducing "simulation says pass, chain says fail" mismatches
Audit and bug-fix pressure in this cycle#
OpenZeppelin incremental audit for this cycle (published 2024-02-20) highlighted:
M-01operations can throttle paymasters (simulation aggregation semantics)M-02ineffective unused-gas penalty edge caseM-03unattributable paymaster fault path (decode/tracing attribution)- client-reported
CR-03insufficient prefund condition that could revert the whole bundle at bundler expense
All were marked resolved in follow-up PRs (including PRs #406, #407, #429, #441, #449).
New risks introduced by the new features#
The upgrades were necessary, but they introduced operational sharp edges:
- packed encoding increased implementation complexity for SDKs and bundlers
- simulation contract split required consistent off-chain tooling behavior
- removing second
postOpmade paymaster design stricter: one cleanup chance - penalty logic itself created new economic-griefing edge cases if not perfectly aligned
v0.8.0: EIP-7702 and hash model expansion#
v0.8 is where ERC-4337 began serious EIP-7702 coexistence.
Major feature changes#
- EIP-7702 support in EntryPoint hashing and sender-init path.
- EIP-712 typed hash path for
getUserOpHash. - stronger/cleaner packed hashing semantics.
ReentrancyGuardTransientbased non-reentrancy model.- additional hardening and error cleanup around paymaster and malformed data.
Code references:
- v0.8
Eip7702Support.sol: https://github.com/eth-infinitism/account-abstraction/blob/v0.8.0/contracts/core/Eip7702Support.sol - v0.8
EntryPoint.solEIP-712 inheritance andgetUserOpHash: https://github.com/eth-infinitism/account-abstraction/blob/v0.8.0/contracts/core/EntryPoint.sol
Why these changes happened#
- network-level trajectory toward 7702 compatibility
- need for a deterministic, explicit typed-data hashing path
- pressure to unify account abstraction flows without forcing one account model
Security and review pressure#
The bundled Spearbit 2024/2025 review stream around this generation called out multiple issues, including:
- mass-invalidation attack surface via missing opcode restrictions (
BLOBHASH/BLOBBASEFEE) in the ERC-7562 rule model - several bundler and spec consistency footguns around validation phases and gas assumptions
These are not always "contract exploit" issues. They are often "network-level bundler loss / DoS" issues.
New risks introduced by this generation#
- EIP-7702 path introduced delegate-code trust and init semantics complexity
- 7702 hash override semantics can be mis-implemented by third-party tooling
- EIP-712 migration can create signer mismatch bugs across clients
- transient-storage based reentrancy model created compatibility assumptions later challenged by EOF execution behavior
v0.9.0: making v0.8 assumptions explicit and safer#
v0.9 is less about broad architecture change and more about hardening the edges exposed by v0.8.
Major feature changes#
- Paymaster signature extension in
paymasterAndData. - Parallel signing flow (account signature and paymaster signature can be produced independently).
getCurrentUserOpHash()support via transient state.- Block-number validity mode (in addition to timestamp mode).
- new events for ignored init code and 7702 account initialization.
- reentrancy guard model changed away from transient-guard dependency.
- stake handling abstraction via new
Stakeablehelper +BasePaymasterrefactor.
Code references:
- v0.9
UserOperationLibpaymaster signature suffix and magic: https://github.com/eth-infinitism/account-abstraction/blob/v0.9.0/contracts/core/UserOperationLib.sol - v0.9
Helpers.solpaymaster-data hash logic: https://github.com/eth-infinitism/account-abstraction/blob/v0.9.0/contracts/core/Helpers.sol - v0.9
EntryPoint.solreentrancy modifier and current userOp hash: https://github.com/eth-infinitism/account-abstraction/blob/v0.9.0/contracts/core/EntryPoint.sol - v0.9
Stakeable.sol: https://github.com/eth-infinitism/account-abstraction/blob/v0.9.0/contracts/core/Stakeable.sol
Paymaster signature encoding in v0.9#
Why these changes happened#
- to reduce coordination friction between account signer and paymaster signer
- to expose current op context to AA-aware contracts (
getCurrentUserOpHash) - to support both timestamp and block-number validity windows
- to patch compatibility hazards discovered after v0.8 guard choices
Important v0.9 security motive: reentrancy guard change#
Release notes explicitly state ReentrancyGuardTransient assumptions could break under EOF transaction behavior in ways that can bypass intended protection. v0.9 switched to an explicit guard (tx.origin == msg.sender && msg.sender.code.length == 0) for entry functions.
That is not a cosmetic change. That is "we learned a lower-level execution assumption was too optimistic".
New risks introduced by v0.9 features#
- paymaster signature not covered by user signature means application designers must treat paymaster policy data carefully
- block-range flag encoding is powerful but parser bugs become consensus-fragmentation risk for tooling
- the new nonReentrant caller constraint changes assumptions for non-EOA callers and integration test setups
UserOperation struct evolution: what changed and why#
Core differences at a glance#
| Topic | v0.6 | v0.7 | v0.8 | v0.9 |
|---|---|---|---|---|
| Struct model | UserOperation | PackedUserOperation | same packed model | same packed model + richer semantics |
| Hash path | legacy pack hash | packed hash | EIP-712 + 7702 override | same + paymaster-signature exclusion logic |
| Paymaster gas | monolithic-ish path | split verification/postOp | same + hardening | same + signature suffix support |
| Simulation split | mostly on EntryPoint | explicit simulation contract model | retained | retained with extra cleanup |
| Reentrancy model | OZ guard | OZ guard | transient guard | explicit custom guard |
DoS and griefing timeline: old versions and what was learned#
The most important failures in this system have repeatedly been economic DoS and simulation mismatch issues.
"Recent DoS problems" to explicitly remember#
-
Mass invalidation vectors
- highlighted in 2025 review context (e.g., opcode-based env leakage paths such as
BLOBHASH/BLOBBASEFEEin rule sets) - impact: bundlers include ops that later fail, paying gas and losing throughput
- highlighted in 2025 review context (e.g., opcode-based env leakage paths such as
-
Insufficient prefund edge
- identified as
CR-03in 2024 incremental audit update process - impact: full bundle can revert at bundler expense under edge accounting conditions
- identified as
-
Attribution failures (
FailedOpquality)- malformed or unattributable paymaster/account errors increase triage cost and delay mitigation
- impact: operational DoS even without direct exploit
-
Revert-data griefing lineage
- old large revert payload handling has long been a griefing axis
- partial early fixes, then repeated hardening
Deep code-diff view across versions#
From local snapshot diffs across contracts/:
v0.6 -> v0.7:64 files changed,+2670 / -1699v0.7 -> v0.8:71 files changed,+1504 / -3176v0.8 -> v0.9:46 files changed,+663 / -206
This confirms what the architecture narrative already suggested:
v0.7andv0.8were structural rewritesv0.9was a focused hardening and semantics-tightening release
New files and interface surface expansion by jump#
v0.6 -> v0.7 notable additions:
contracts/core/EntryPointSimulations.solcontracts/core/UserOperationLib.solcontracts/interfaces/PackedUserOperation.solcontracts/interfaces/IEntryPointSimulations.solcontracts/interfaces/IAccountExecute.sol
v0.7 -> v0.8 notable additions:
contracts/core/Eip7702Support.solcontracts/accounts/Simple7702Account.solcontracts/legacy/v06/*compatibility interfaces
v0.8 -> v0.9 notable additions:
contracts/core/Stakeable.solcontracts/test/TestCurrentUserOpHash.solcontracts/test/TestPaymasterWithSig.sol
Why this matters for auditors#
When file count explodes, variant risk explodes:
- every new encoding helper can create mismatch classes
- every new optional path (e.g., 7702, paymaster signatures) creates parser split risk
- every "legacy compatibility" interface can preserve old assumptions accidentally
Audit-fix matrix by generation#
| Period | Finding class | Impact style | Fix status direction |
|---|---|---|---|
| 2023 incremental audit (v0.6 era) | warm/cold simulation mismatch | bundler gas-loss DoS | fixed by redesigning validation flow in later generations |
| 2023 incremental audit (v0.6 era) | revert reason bombing | griefing and attribution cost | partially fixed first, then hardened over later releases |
| 2024 incremental audit (v0.7 cycle) | paymaster throttling semantics (M-01) | false reputation damage and throttling | fixed (#406) |
| 2024 incremental audit (v0.7 cycle) | ineffective unused gas penalty (M-02) | economic bundle-space griefing | fixed (#407) |
| 2024 incremental audit (v0.7 cycle) | unattributable paymaster fault (M-03) | operational triage DoS | fixed via tracing-first approach (#429) |
| 2024 incremental audit (v0.7 cycle) | insufficient prefund (CR-03) | bundle revert at bundler expense | fixed (#441, #449) |
| 2025 Spearbit review (v0.8/v0.9 transition) | BLOBHASH and BLOBBASEFEE mass invalidation vector | broad bundler gas-loss DoS | fixed in rule/docs + bundler updates (#901, bundler updates) |
| 2025 Spearbit review | 7702/accounting/spec mismatch footguns | inconsistent client behavior | fixed across multiple PRs before v0.9 line |
The key pattern in all fixes#
Most "DoS" fixes were not one-line contract patches. They were three-layer patches:
- EntryPoint behavior correction
- ERC text correction
- Bundler simulation and policy correction
That three-layer dependency is why old versions can remain "battle-tested" but still operationally dangerous under modern traffic and adversarial behavior.
Deployment and compatibility pressure across versions#
Each version changed not only code but ecosystem assumptions:
- bundlers had to support the right EntryPoint addresses per network/version
- SDKs had to serialize the right packed fields and optional suffixes
- simulation tooling had to remain aligned with validation semantics
This is also why external tooling docs (for example viem and ERC-4337 docs pages) matter operationally, even though canonical behavior is still defined by EntryPoint code and ERC text.
Battle-tested vs "fixed all old problems"#
These are not the same claim.
Practical interpretation#
v0.6is battle-tested but carries old design assumptions and known rough edges.v0.7fixed major accounting/simulation issues but introduced new complexity in split gas + bundler logic.v0.8enabled critical future compatibility (7702) but created fresh assumptions that needed v0.9 hardening.v0.9is the current "security posture upgrade", not the end of evolution.
So the right mental model is:
- battle-tested means "we now know many failure modes"
- not "failure modes are exhausted"
Feature-by-feature: what was added when and why#
1. Packed UserOp (v0.7)#
Why:
- lower calldata overhead
- cleaner gas field structure
Risk introduced:
- tooling encoding/parsing mismatch risk
2. Split paymaster gas limits (v0.7)#
Why:
- decouple verification and postOp accounting
- improve fee predictability
Risk introduced:
- incorrect bundler defaults can still over/under-estimate cost
3. Unused gas penalty (v0.7, hardened later)#
Why:
- prevent bundle-space hoarding by over-reserving gas
Risk introduced:
- penalty-edge economic weirdness if exclusions exist
4. EIP-7702 support (v0.8)#
Why:
- converge AA infra with 7702 delegation model
Risk introduced:
- delegate trust and hashing complexity
5. EIP-712 hash path (v0.8)#
Why:
- standard typed-data hash semantics
Risk introduced:
- signer domain mismatch across clients
6. Paymaster signature suffix (v0.9)#
Why:
- allow account and paymaster signatures in parallel
- lower integration latency and coordination friction
Risk introduced:
- user signature no longer commits paymaster signature bytes
- app-level policy binding must be explicit
7. Block-range validity flag (v0.9)#
Why:
- support both timestamp and block-based validity
Risk introduced:
- parser inconsistency risk across clients and bundlers
Code map for auditors and integrators#
If you are auditing or integrating today, these are the highest-signal files:
EntryPoint.solacross tags:- v0.6: foundational behavior
- v0.7: packed ops + accounting shifts
- v0.8: 7702 + EIP-712 path
- v0.9: nonReentrant rewrite, current op hash, block validity mode
UserOperationLib.sol(v0.9): paymaster signature parsing and encodingHelpers.sol(v0.9): paymaster data keccak excluding dynamic suffixEntryPointSimulations.sol: simulation model assumptions and mismatch defensesBasePaymaster.solandStakeable.sol(v0.9): staking and ownership model evolution
Migration strategy: choosing your target#
Closing: the real evolution pattern#
EIP-4337 version evolution is not linear feature accumulation. It is iterative adversarial hardening.
- v0.6: production baseline
- v0.7: accounting/simulation correction wave
- v0.8: 7702 and hash expansion
- v0.9: compatibility and hardening corrections to v0.8 assumptions
The biggest strategic takeaway is this:
battle-tested should increase your confidence in known failure handling, not make you dismiss new failure classes introduced by new capability.
If you are building on 4337 now, operate like this:
- track EntryPoint version semantics explicitly
- treat bundler simulation rules as part of your security boundary
- model paymaster griefing and attribution quality as first-class
- pin hash/signature assumptions end-to-end in tests