{"eip":7523,"title":"Empty accounts deprecation","description":"Prohibit empty accounts on post-merge networks","authors":["Peter Davies (@petertdavies)"],"status":"Last Call","type":"Standards Track","category":"Core","created":"2023-09-19","requires":[161],"discussionsTo":"https://ethereum-magicians.org/t/eip-7523-empty-accounts-deprecation/15870","repo":"EIPs","label":"EIP-7523","officialUrl":"https://eips.ethereum.org/EIPS/eip-7523","sourceUrl":"https://github.com/ethereum/EIPs/blob/master/EIPS/eip-7523.md","url":"https://eips.huatuo.xyz/eip-7523/","tldr":{"en":"Declares that post-merge Ethereum state never contains empty accounts, so clients and future specs can drop EIP-161's complicated 'touch and delete' edge cases.","ja":"マージ後の Ethereum のステートには空のアカウントが存在しないと宣言する。これにより、クライアントや将来の仕様が、EIP-161 の複雑な「touch して削除」のエッジケースを切り捨てられるようになる。","ko":"머지 이후 이더리움 상태에는 빈 계정이 존재하지 않는다고 선언해, 클라이언트와 향후 명세가 EIP-161의 복잡한 \"touch 후 삭제\" 엣지 케이스를 버릴 수 있게 한다.","zh":"声明合并（Merge）之后的以太坊状态中不存在空账户，使客户端和未来的规范可以舍弃 EIP-161 中复杂的“touch 并删除”边界情况。"},"tags":["core","state","accounts","cleanup","technical-debt"],"explainers":{"en":{"lang":"en","tldr":"Declares that post-merge Ethereum state never contains empty accounts, so clients and future specs can drop EIP-161's complicated 'touch and delete' edge cases.","tags":["core","state","accounts","cleanup","technical-debt"],"related":[161,158,7610],"updated":"2026-10-19","url":"https://eips.huatuo.xyz/eip-7523/","markdown":"## What problem does it solve?\n\nAn **empty account** has no code, a zero nonce and a zero balance. In Ethereum's early days, the 2016 Shanghai DoS attacks created huge numbers of them. [EIP-161](/eip-161/) (Spurious Dragon) stopped new ones from being created and added a rule that an empty account is deleted when it is \"touched\".\n\nThose leftovers have since been cleaned up: the spec notes that all remaining empty accounts on Mainnet were cleared in block 14049881, months before the merge. Yet the \"touch\" rules still sit in the specification. Every new feature has to consider how it interacts with them, test suites contain cases for them, and a new client that only wants to support post-merge blocks must still implement them just to pass tests.\n\nEIP-7523 removes that burden by formally ruling out empty accounts after the merge.\n\n## How it works\n\nThe EIP changes no behaviour that can actually happen on a live network. It adds a rule:\n\n- On networks that went through the merge, the pre-state of the merge block must not contain empty accounts.\n- On networks merged at genesis, no genesis account may be empty.\n- The specification is **undefined** in the presence of a post-merge empty account, and test cases involving them are invalid.\n\nClients may skip scanning state to confirm this for:\n\n1. Mainnet (identified in the spec by its merge block hash), and\n2. any chain with no empty genesis accounts that had Spurious Dragon (or later) rules active at genesis.\n\nThe merge was chosen as the cutoff because it is a clear, easily identified point. Earlier cutoffs or narrower edge-case lists were considered and rejected as unnecessarily complicated.\n\n## Sample code\n\nThe definition, and the code path implementers no longer need for post-merge blocks (pseudocode):\n\n```python\ndef is_empty(account) -\u003e bool:\n    return account.nonce == 0 and account.balance == 0 and len(account.code) == 0\n\n# EIP-161 rule: at the end of a transaction, delete touched accounts that are empty.\n# Under EIP-7523, post-merge state can never contain an empty account,\n# so this cleanup can never fire and need not be implemented for post-merge-only clients.\ndef destroy_touched_empty_accounts(state, touched):\n    for addr in touched:\n        if addr in state and is_empty(state[addr]):\n            del state[addr]\n```\n\n## Things to know\n\n- Status is **Last Call**: it is close to final but not yet Final.\n- It is a clean-up rule, not a fork that changes execution. No transaction behaves differently.\n- Its validity depends on the claim that all Mainnet empty accounts were cleared before the merge; the spec asks that this be independently verified.\n- Private or test networks deliberately configured with empty accounts in genesis will cause problems with tooling and clients that rely on this rule.\n- Related clean-up of historical edge cases: [EIP-7610](/eip-7610/) handles contract creation at addresses with non-empty storage.\n"},"ja":{"lang":"ja","tldr":"マージ後の Ethereum のステートには空のアカウントが存在しないと宣言する。これにより、クライアントや将来の仕様が、EIP-161 の複雑な「touch して削除」のエッジケースを切り捨てられるようになる。","tags":["core","state","accounts","cleanup","technical-debt"],"related":[161,158,7610],"updated":"2026-10-19","url":"https://eips.huatuo.xyz/ja/eip-7523/","markdown":"## 何を解決するのか\n\n**空のアカウント**とは、コードがなく、nonce がゼロで、残高もゼロのアカウントです。Ethereum の初期、2016 年の Shanghai DoS 攻撃によって、大量の空アカウントが作られました。[EIP-161](/eip-161/)（Spurious Dragon）は新たな作成を止め、空のアカウントは「touch」されたときに削除されるというルールを加えました。\n\nその後、これらの残骸は一掃されました。仕様によると、Mainnet に残っていた空のアカウントはすべて、マージの数か月前のブロック 14049881 で消去されています。それでも「touch」のルールは今も仕様に残っています。新機能はそのたびにルールとの相互作用を考慮する必要があり、テストスイートにはそのためのケースが含まれ、マージ後のブロックだけをサポートしたい新しいクライアントも、テストを通すためだけにそれを実装しなければなりません。\n\nEIP-7523 は、マージ後に空のアカウントが存在しないことを正式に定めることで、この負担を取り除きます。\n\n## 仕組み\n\nこの EIP は、稼働中のネットワークで実際に起こり得る動作を何も変えません。次のルールを追加します。\n\n- マージを経たネットワークでは、マージブロックの事前ステートに空のアカウントが含まれていてはなりません。\n- ジェネシスの時点でマージ済みのネットワークでは、ジェネシスのアカウントが空であってはなりません。\n- マージ後に空のアカウントが存在する場合、仕様は**未定義**となり、それを含むテストケースは無効です。\n\nクライアントは、次の場合、これを確認するためのステートのスキャンを省略できます。\n\n1. Mainnet（仕様ではマージブロックのハッシュで特定）、および\n2. ジェネシスに空のアカウントがなく、ジェネシスの時点で Spurious Dragon（またはそれ以降）のルールが有効だった任意のチェーン。\n\nマージが区切りとして選ばれたのは、明確で特定しやすい時点だからです。より早い区切りや、より限定的なエッジケースの一覧も検討されましたが、不必要に複雑になるとして却下されました。\n\n## サンプルコード\n\n定義と、マージ後のブロックでは実装者が不要になるコードパス（擬似コード）:\n\n```python\ndef is_empty(account) -\u003e bool:\n    return account.nonce == 0 and account.balance == 0 and len(account.code) == 0\n\n# EIP-161 rule: at the end of a transaction, delete touched accounts that are empty.\n# Under EIP-7523, post-merge state can never contain an empty account,\n# so this cleanup can never fire and need not be implemented for post-merge-only clients.\ndef destroy_touched_empty_accounts(state, touched):\n    for addr in touched:\n        if addr in state and is_empty(state[addr]):\n            del state[addr]\n```\n\n## 知っておくべきこと\n\n- ステータスは **Last Call** です。ほぼ最終ですが、まだ Final ではありません。\n- これは整理のためのルールであり、実行を変えるフォークではありません。動作が変わるトランザクションはありません。\n- その妥当性は、Mainnet の空のアカウントがすべてマージ前に消去されたという主張に依存しており、仕様はこれを独立に検証することを求めています。\n- ジェネシスに空のアカウントを意図的に設定したプライベートネットワークやテストネットワークでは、このルールに依存するツールやクライアントで問題が起こります。\n- 過去のエッジケースに関する関連の整理: [EIP-7610](/eip-7610/) は、空でないストレージを持つアドレスでのコントラクト作成を扱います。\n"},"ko":{"lang":"ko","tldr":"머지 이후 이더리움 상태에는 빈 계정이 존재하지 않는다고 선언해, 클라이언트와 향후 명세가 EIP-161의 복잡한 \"touch 후 삭제\" 엣지 케이스를 버릴 수 있게 한다.","tags":["core","state","accounts","cleanup","technical-debt"],"related":[161,158,7610],"updated":"2026-10-19","url":"https://eips.huatuo.xyz/ko/eip-7523/","markdown":"## 어떤 문제를 해결하나요?\n\n**빈 계정**은 코드가 없고 nonce가 0이며 잔액도 0인 계정입니다. 이더리움 초기였던 2016년 상하이 DoS 공격으로 이런 계정이 대량으로 만들어졌습니다. [EIP-161](/eip-161/)(Spurious Dragon)은 새 빈 계정의 생성을 막고, 빈 계정이 \"touch\"되면 삭제된다는 규칙을 추가했습니다.\n\n이 잔재는 이후 정리되었습니다. 명세에 따르면 메인넷에 남아 있던 빈 계정은 머지 몇 달 전인 블록 14049881에서 모두 지워졌습니다. 그런데도 \"touch\" 규칙은 여전히 명세에 남아 있습니다. 새 기능은 매번 이 규칙과 어떻게 상호작용하는지 고려해야 하고, 테스트 스위트에는 이를 위한 케이스가 들어 있으며, 머지 이후 블록만 지원하려는 새 클라이언트도 테스트를 통과하려면 이를 구현해야 합니다.\n\nEIP-7523은 머지 이후에는 빈 계정이 없다고 공식적으로 못 박아 이 부담을 덜어 줍니다.\n\n## 어떻게 동작하나요?\n\n이 EIP는 실제 운영 중인 네트워크에서 일어날 수 있는 동작을 하나도 바꾸지 않습니다. 다음 규칙을 추가합니다.\n\n- 머지를 거친 네트워크에서는 머지 블록의 사전 상태(pre-state)에 빈 계정이 있어서는 안 됩니다.\n- 제네시스 시점에 머지된 네트워크에서는 제네시스 계정이 비어 있어서는 안 됩니다.\n- 머지 이후에 빈 계정이 있으면 명세는 **정의되지 않으며**, 이를 포함하는 테스트 케이스는 유효하지 않습니다.\n\n클라이언트는 다음의 경우 이를 확인하기 위한 상태 스캔을 생략할 수 있습니다.\n\n1. 메인넷(명세에서는 머지 블록 해시로 식별), 그리고\n2. 제네시스에 빈 계정이 없고 제네시스 시점에 Spurious Dragon(또는 그 이후) 규칙이 활성화되어 있던 모든 체인.\n\n머지를 기준점으로 고른 것은 분명하고 쉽게 식별되는 시점이기 때문입니다. 더 이른 기준점이나 범위가 더 좁은 엣지 케이스 목록도 검토되었지만 불필요하게 복잡하다는 이유로 기각되었습니다.\n\n## 샘플 코드\n\n정의와, 머지 이후 블록에서는 구현자에게 더 이상 필요하지 않은 코드 경로(의사 코드):\n\n```python\ndef is_empty(account) -\u003e bool:\n    return account.nonce == 0 and account.balance == 0 and len(account.code) == 0\n\n# EIP-161 rule: at the end of a transaction, delete touched accounts that are empty.\n# Under EIP-7523, post-merge state can never contain an empty account,\n# so this cleanup can never fire and need not be implemented for post-merge-only clients.\ndef destroy_touched_empty_accounts(state, touched):\n    for addr in touched:\n        if addr in state and is_empty(state[addr]):\n            del state[addr]\n```\n\n## 알아둘 점\n\n- 상태는 **Last Call**입니다. 최종에 가깝지만 아직 Final은 아닙니다.\n- 이는 실행을 바꾸는 포크가 아니라 정리 규칙입니다. 동작이 달라지는 트랜잭션은 없습니다.\n- 타당성은 메인넷의 빈 계정이 모두 머지 이전에 지워졌다는 주장에 달려 있으며, 명세는 이를 독립적으로 검증할 것을 요구합니다.\n- 제네시스에 빈 계정을 일부러 넣어 둔 프라이빗 또는 테스트 네트워크는 이 규칙에 의존하는 도구와 클라이언트에서 문제를 일으킵니다.\n- 과거 엣지 케이스에 관한 관련 정리: [EIP-7610](/eip-7610/)은 스토리지가 비어 있지 않은 주소에서의 컨트랙트 생성을 다룹니다.\n"},"zh":{"lang":"zh","tldr":"声明合并（Merge）之后的以太坊状态中不存在空账户，使客户端和未来的规范可以舍弃 EIP-161 中复杂的“touch 并删除”边界情况。","tags":["core","state","accounts","cleanup","technical-debt"],"related":[161,158,7610],"updated":"2026-10-19","url":"https://eips.huatuo.xyz/zh/eip-7523/","markdown":"## 它解决什么问题？\n\n**空账户**是指没有代码、nonce 为零、余额也为零的账户。在以太坊早期，2016 年的上海 DoS 攻击创建了大量这样的账户。[EIP-161](/eip-161/)（Spurious Dragon）阻止了新的空账户产生，并增加了一条规则：空账户在被\"touch\"时会被删除。\n\n这些遗留的账户后来已被清理：规范指出，主网上剩余的所有空账户都在区块 14049881 被清除，比合并早了几个月。然而\"touch\"规则仍然留在规范中。每个新特性都必须考虑它与这些规则如何交互，测试套件中包含相关用例，而只想支持合并后区块的新客户端，为了通过测试也必须实现它们。\n\nEIP-7523 通过正式排除合并后的空账户，消除了这一负担。\n\n## 它如何运作\n\n这个 EIP 不改变任何在实际网络中可能发生的行为。它增加了一条规则：\n\n- 对于经历过合并的网络，合并区块的前置状态不得包含空账户。\n- 对于创世时就已合并的网络，任何创世账户都不得为空。\n- 当合并后存在空账户时，规范是**未定义**的，涉及空账户的测试用例无效。\n\n在以下情况下，客户端可以跳过为确认这一点而扫描状态的步骤：\n\n1. 主网（规范中通过其合并区块哈希来标识），以及\n2. 创世账户中没有空账户、且在创世时 Spurious Dragon（或更晚）规则已经生效的任何链。\n\n选择合并作为分界点，是因为它是一个清晰、容易识别的节点。更早的分界点或范围更窄的边界情况清单也曾被考虑过，但因过于复杂而被否决。\n\n## 示例代码\n\n定义，以及合并后区块中实现者不再需要的代码路径（伪代码）：\n\n```python\ndef is_empty(account) -\u003e bool:\n    return account.nonce == 0 and account.balance == 0 and len(account.code) == 0\n\n# EIP-161 rule: at the end of a transaction, delete touched accounts that are empty.\n# Under EIP-7523, post-merge state can never contain an empty account,\n# so this cleanup can never fire and need not be implemented for post-merge-only clients.\ndef destroy_touched_empty_accounts(state, touched):\n    for addr in touched:\n        if addr in state and is_empty(state[addr]):\n            del state[addr]\n```\n\n## 需要注意\n\n- 状态为 **Last Call**：接近最终，但尚未达到 Final。\n- 这是一条清理规则，而不是改变执行的分叉。没有任何交易的行为会因此不同。\n- 它的有效性取决于\"主网所有空账户都在合并前被清除\"这一说法；规范要求对此进行独立验证。\n- 在创世中刻意配置了空账户的私有网络或测试网络，会让依赖该规则的工具和客户端出现问题。\n- 对历史边界情况的相关清理：[EIP-7610](/eip-7610/) 处理的是在存储非空的地址上创建合约的情形。\n"}},"requiredBy":[5920,7675,8347]}
