{"eip":7806,"title":"Minimal intent-centric EOA smart account","description":"Extensible intent-centric EOA smart account interface design to support batch execution, gas sponsorship and more other functionalities.","authors":["hellohanchen (@hellohanchen)"],"status":"Draft","type":"Standards Track","category":"ERC","created":"2024-11-02","requires":[7702],"discussionsTo":"https://ethereum-magicians.org/t/erc-7806-minimal-intent-centric-eoa-smart-account/21565","repo":"ERCs","label":"ERC-7806","officialUrl":"https://eips.ethereum.org/EIPS/eip-7806","sourceUrl":"https://github.com/ethereum/ERCs/blob/master/ERCS/erc-7806.md","url":"https://eips.huatuo.xyz/eip-7806/","tldr":{"en":"A minimal smart-account interface for EOAs that delegate code via EIP-7702: the owner signs a packed intent, any solver or relayer submits it, and a pluggable \"standard\" contract validates and unpacks it into calls.","ja":"EIP-7702 でコードを委任する EOA 向けの最小限のスマートアカウントインターフェース。オーナーがパックされたインテントに署名し、任意のソルバーやリレイヤーがそれを送信し、差し替え可能な「standard」コントラクトがそれを検証して呼び出しへと展開する。","ko":"EIP-7702로 코드를 위임하는 EOA를 위한 최소한의 스마트 계정 인터페이스. 소유자가 패킹된 인텐트에 서명하면 누구든 솔버나 릴레이어가 제출하고, 교체 가능한 \"standard\" 컨트랙트가 이를 검증하고 호출들로 풀어낸다.","zh":"面向通过 EIP-7702 委托代码的 EOA 的极简智能账户接口：所有者签署一个打包的意图，任何求解者或中继者都可以提交，由可插拔的\"standard\"合约验证并将其展开为一系列调用。"},"tags":["account-abstraction","intents","eip-7702","eoa","gas-sponsorship","draft"],"explainers":{"en":{"lang":"en","tldr":"A minimal smart-account interface for EOAs that delegate code via EIP-7702: the owner signs a packed intent, any solver or relayer submits it, and a pluggable \"standard\" contract validates and unpacks it into calls.","tags":["account-abstraction","intents","eip-7702","eoa","gas-sponsorship","draft"],"related":[7702,4337,7521,6900,7579],"updated":"2026-10-19","url":"https://eips.huatuo.xyz/eip-7806/","markdown":"## What problem does it solve?\n\nAccount abstraction brings batching, gas sponsorship and flexible access control. [ERC-4337](/eip-4337/) delivers this, but with many moving parts (account, EntryPoint, paymaster, bundler, plugin standards such as [ERC-6900](/eip-6900/) and [ERC-7579](/eip-7579/)), relatively high gas per `UserOperation`, coordinated upgrades, and practical reliance on paymasters and bundlers.\n\n[EIP-7702](/eip-7702/) lets a plain EOA point to contract code. ERC-7806 uses that to give EOAs a deliberately small, **intent-centric** smart-account interface, in the spirit of [ERC-7521](/eip-7521/): the user signs *what* should happen, and an open market of solvers/relayers executes it, possibly paying gas in ETH and getting reimbursed in tokens from the account.\n\n## How it works\n\n**UserIntent.** A packed `bytes` blob with five logical parts:\n\n| Field | Meaning |\n| --- | --- |\n| `sender` | The EOA the intent is for |\n| `standard` | Address of the `IStandard` contract that knows how to read this intent |\n| `header` | Metadata, e.g. a nonce or expiry, interpreted by the standard |\n| `instructions` | What to do, e.g. `(to, value, calldata)` items or token spend limits |\n| `signatures` | Signatures the standard checks (not necessarily all from the owner) |\n\nThe suggested encoding is `sender (20) ‖ standard (20) ‖ three uint16 lengths ‖ header ‖ instructions ‖ signatures ‖ extra`, but each standard may define its own.\n\n**Two interfaces.**\n\n- `IStandard.validateUserIntent(bytes) → bytes4` and `IStandard.unpackOperations(bytes) → (bytes4, bytes[])`. The standard holds the validation rules, like a slimmed-down EntryPoint.\n- `IAccount.executeUserIntent(bytes) → bytes`. Implemented by the code the EOA delegates to; it asks the standard to validate/unpack, then executes the operations as the EOA, so `msg.sender` downstream is the EOA itself.\n\n**Gas abstraction.** Anyone can submit the transaction. The intent can tell the account to pay the submitter (`tx.origin`) in any token, so the user never needs ETH for gas. Solvers may also batch many intents in one transaction.\n\nReplay protection is **not** global: each standard decides (one-shot hashes, nonces, expiry), because some intents are meant to run repeatedly.\n\n## Sample code\n\nA minimal stateless account that trusts a single standard (Solidity, illustrative):\n\n```solidity\n// SPDX-License-Identifier: MIT\npragma solidity ^0.8.20;\n\ninterface IStandard {\n    function validateUserIntent(bytes calldata intent) external view returns (bytes4);\n    function unpackOperations(bytes calldata intent) external view returns (bytes4, bytes[] memory);\n}\n\ncontract MinimalIntentAccount {\n    bytes4 constant APPROVED = 0x00000001;\n    IStandard public immutable standard; // code is shared; no per-EOA storage\n\n    constructor(IStandard s) { standard = s; }\n\n    function executeUserIntent(bytes calldata intent) external returns (bytes memory) {\n        require(address(bytes20(intent[0:20])) == address(this), \"wrong sender\");\n        require(address(bytes20(intent[20:40])) == address(standard), \"unknown standard\");\n\n        (bytes4 code, bytes[] memory ops) = standard.unpackOperations(intent);\n        require(code == APPROVED, \"rejected\");\n\n        for (uint256 i; i \u003c ops.length; ++i) {\n            (address to, uint256 value, bytes memory data) = abi.decode(ops[i], (address, uint256, bytes));\n            (bool ok, ) = to.call{value: value}(data);\n            require(ok, \"op failed\");\n        }\n        return \"\";\n    }\n}\n```\n\n## Things to know\n\n- **Status: Draft.** Parts of the text are unfinished (for example, a list of recommended re-entry protections is left empty).\n- Security rests on the chosen `IStandard` and `IAccount` code. Both should be public and audited, and the EOA owner must only delegate to trusted implementations.\n- Stateless account code is strongly recommended: delegated EOAs share storage across whatever code they point to, so stored state can clash or be abused.\n- The reference implementation in the spec is illustrative; review it carefully rather than deploying it as-is.\n- The EOA's private key still has full control; un-delegating disables all smart-account behaviour.\n"},"ja":{"lang":"ja","tldr":"EIP-7702 でコードを委任する EOA 向けの最小限のスマートアカウントインターフェース。オーナーがパックされたインテントに署名し、任意のソルバーやリレイヤーがそれを送信し、差し替え可能な「standard」コントラクトがそれを検証して呼び出しへと展開する。","tags":["account-abstraction","intents","eip-7702","eoa","gas-sponsorship","draft"],"related":[7702,4337,7521,6900,7579],"updated":"2026-10-19","url":"https://eips.huatuo.xyz/ja/eip-7806/","markdown":"## 何を解決するのか\n\nアカウントアブストラクションは、バッチ処理、ガス代のスポンサー、柔軟なアクセス制御をもたらします。[ERC-4337](/eip-4337/) はこれを実現しますが、構成要素が多く（アカウント、EntryPoint、Paymaster、Bundler、[ERC-6900](/eip-6900/) や [ERC-7579](/eip-7579/) のようなプラグイン標準）、`UserOperation` あたりのガスが比較的高く、アップグレードに調整が必要で、実際には Paymaster と Bundler に依存します。\n\n[EIP-7702](/eip-7702/) は、通常の EOA にコントラクトコードを指させることを可能にします。ERC-7806 はそれを利用して、[ERC-7521](/eip-7521/) の精神に沿った、意図的に小さな**インテント中心**のスマートアカウントインターフェースを EOA に与えます。ユーザーは「何が起こるべきか」に署名し、ソルバー／リレイヤーのオープンな市場がそれを実行します。ガス代は ETH で支払い、アカウントからトークンで払い戻しを受けることもできます。\n\n## 仕組み\n\n**UserIntent。** 5 つの論理的な部分を持つ、パックされた `bytes` の塊です。\n\n| フィールド | 意味 |\n| --- | --- |\n| `sender` | このインテントの対象となる EOA |\n| `standard` | このインテントの読み方を知っている `IStandard` コントラクトのアドレス |\n| `header` | nonce や有効期限などのメタデータ。standard が解釈する |\n| `instructions` | 何をするか。例えば `(to, value, calldata)` の項目やトークンの支出上限 |\n| `signatures` | standard が検証する署名（必ずしもすべてオーナーによるものとは限らない） |\n\n推奨されるエンコーディングは `sender (20) ‖ standard (20) ‖ three uint16 lengths ‖ header ‖ instructions ‖ signatures ‖ extra` ですが、各 standard が独自に定義してもかまいません。\n\n**2 つのインターフェース。**\n\n- `IStandard.validateUserIntent(bytes) → bytes4` と `IStandard.unpackOperations(bytes) → (bytes4, bytes[])`。standard が検証ルールを保持します。簡素化された EntryPoint のようなものです。\n- `IAccount.executeUserIntent(bytes) → bytes`。EOA が委任先とするコードが実装します。standard に検証と展開を依頼し、その後 EOA として operation を実行するため、下流の `msg.sender` は EOA 自身になります。\n\n**ガスの抽象化。** トランザクションは誰でも送信できます。インテントはアカウントに、送信者（`tx.origin`）へ任意のトークンで支払うよう指示できるため、ユーザーはガス代のために ETH を持つ必要がありません。ソルバーは多数のインテントを 1 つのトランザクションにまとめることもできます。\n\nリプレイ保護はグローバルでは**ありません**。インテントによっては繰り返し実行されることを意図したものがあるため、各 standard が決めます（1 回限りのハッシュ、nonce、有効期限）。\n\n## サンプルコード\n\n単一の standard を信頼する、最小限のステートレスアカウント（Solidity、説明用）:\n\n```solidity\n// SPDX-License-Identifier: MIT\npragma solidity ^0.8.20;\n\ninterface IStandard {\n    function validateUserIntent(bytes calldata intent) external view returns (bytes4);\n    function unpackOperations(bytes calldata intent) external view returns (bytes4, bytes[] memory);\n}\n\ncontract MinimalIntentAccount {\n    bytes4 constant APPROVED = 0x00000001;\n    IStandard public immutable standard; // code is shared; no per-EOA storage\n\n    constructor(IStandard s) { standard = s; }\n\n    function executeUserIntent(bytes calldata intent) external returns (bytes memory) {\n        require(address(bytes20(intent[0:20])) == address(this), \"wrong sender\");\n        require(address(bytes20(intent[20:40])) == address(standard), \"unknown standard\");\n\n        (bytes4 code, bytes[] memory ops) = standard.unpackOperations(intent);\n        require(code == APPROVED, \"rejected\");\n\n        for (uint256 i; i \u003c ops.length; ++i) {\n            (address to, uint256 value, bytes memory data) = abi.decode(ops[i], (address, uint256, bytes));\n            (bool ok, ) = to.call{value: value}(data);\n            require(ok, \"op failed\");\n        }\n        return \"\";\n    }\n}\n```\n\n## 知っておくべきこと\n\n- **ステータス: Draft。** 文章の一部は未完成です（たとえば、推奨される再入保護のリストは空のままです）。\n- セキュリティは、選択した `IStandard` と `IAccount` のコードにかかっています。どちらも公開され、監査されているべきで、EOA のオーナーは信頼できる実装にのみ委任しなければなりません。\n- ステートレスなアカウントコードを強く推奨します。委任された EOA は、指し示すコードが何であれ、その間でストレージを共有するため、保存された状態が衝突したり悪用されたりしうるためです。\n- 仕様内のリファレンス実装は説明用です。そのままデプロイせず、慎重にレビューしてください。\n- EOA の秘密鍵は依然として完全な制御権を持ちます。委任を解除すると、スマートアカウントとしての動作はすべて無効になります。\n"},"ko":{"lang":"ko","tldr":"EIP-7702로 코드를 위임하는 EOA를 위한 최소한의 스마트 계정 인터페이스. 소유자가 패킹된 인텐트에 서명하면 누구든 솔버나 릴레이어가 제출하고, 교체 가능한 \"standard\" 컨트랙트가 이를 검증하고 호출들로 풀어낸다.","tags":["account-abstraction","intents","eip-7702","eoa","gas-sponsorship","draft"],"related":[7702,4337,7521,6900,7579],"updated":"2026-10-19","url":"https://eips.huatuo.xyz/ko/eip-7806/","markdown":"## 어떤 문제를 해결하나요?\n\n계정 추상화는 일괄 처리, 가스 대납, 유연한 접근 제어를 가져옵니다. [ERC-4337](/eip-4337/)이 이를 제공하지만 구성 요소가 많고(계정, EntryPoint, paymaster, bundler, [ERC-6900](/eip-6900/)과 [ERC-7579](/eip-7579/) 같은 플러그인 표준), `UserOperation`당 가스가 비교적 높으며, 업그레이드에 조율이 필요하고, 실제로는 paymaster와 bundler에 의존하게 됩니다.\n\n[EIP-7702](/eip-7702/)는 일반 EOA가 컨트랙트 코드를 가리키게 해 줍니다. ERC-7806은 이를 이용해 [ERC-7521](/eip-7521/)의 정신에 따라 EOA에 의도적으로 작은 **인텐트 중심** 스마트 계정 인터페이스를 줍니다. 사용자는 *무엇이 일어나야 하는지*에 서명하고, 솔버/릴레이어의 열린 시장이 이를 실행합니다. 이들은 ETH로 가스를 내고 계정에서 토큰으로 상환받을 수도 있습니다.\n\n## 어떻게 동작하나요?\n\n**UserIntent.** 다섯 개의 논리적 부분으로 이루어진 패킹된 `bytes` 덩어리입니다.\n\n| 필드 | 의미 |\n| --- | --- |\n| `sender` | 인텐트의 대상이 되는 EOA |\n| `standard` | 이 인텐트를 읽는 방법을 아는 `IStandard` 컨트랙트의 주소 |\n| `header` | nonce나 만료 시각 같은 메타데이터로, standard가 해석 |\n| `instructions` | 무엇을 할지. 예: `(to, value, calldata)` 항목이나 토큰 지출 한도 |\n| `signatures` | standard가 검사하는 서명(반드시 모두 소유자의 것은 아님) |\n\n권장 인코딩은 `sender (20) ‖ standard (20) ‖ three uint16 lengths ‖ header ‖ instructions ‖ signatures ‖ extra`이지만, 각 standard가 자체적으로 정의할 수도 있습니다.\n\n**두 가지 인터페이스.**\n\n- `IStandard.validateUserIntent(bytes) → bytes4`와 `IStandard.unpackOperations(bytes) → (bytes4, bytes[])`. standard가 검증 규칙을 가집니다. 간소화된 EntryPoint 같은 것입니다.\n- `IAccount.executeUserIntent(bytes) → bytes`. EOA가 위임한 코드가 구현합니다. standard에게 검증과 풀어내기를 요청한 뒤 EOA로서 operation을 실행하므로, 하위 호출에서의 `msg.sender`는 EOA 자신이 됩니다.\n\n**가스 추상화.** 누구든 트랜잭션을 제출할 수 있습니다. 인텐트는 계정에게 제출자(`tx.origin`)에게 어떤 토큰으로든 지급하라고 지시할 수 있으므로, 사용자는 가스를 위해 ETH를 가질 필요가 없습니다. 솔버는 여러 인텐트를 하나의 트랜잭션에 묶을 수도 있습니다.\n\n재전송 방지는 전역적이지 **않습니다**. 어떤 인텐트는 반복 실행되도록 의도되었기 때문에 각 standard가 결정합니다(일회성 해시, nonce, 만료).\n\n## 샘플 코드\n\n단일 standard만 신뢰하는 최소한의 무상태 계정(Solidity, 설명용):\n\n```solidity\n// SPDX-License-Identifier: MIT\npragma solidity ^0.8.20;\n\ninterface IStandard {\n    function validateUserIntent(bytes calldata intent) external view returns (bytes4);\n    function unpackOperations(bytes calldata intent) external view returns (bytes4, bytes[] memory);\n}\n\ncontract MinimalIntentAccount {\n    bytes4 constant APPROVED = 0x00000001;\n    IStandard public immutable standard; // code is shared; no per-EOA storage\n\n    constructor(IStandard s) { standard = s; }\n\n    function executeUserIntent(bytes calldata intent) external returns (bytes memory) {\n        require(address(bytes20(intent[0:20])) == address(this), \"wrong sender\");\n        require(address(bytes20(intent[20:40])) == address(standard), \"unknown standard\");\n\n        (bytes4 code, bytes[] memory ops) = standard.unpackOperations(intent);\n        require(code == APPROVED, \"rejected\");\n\n        for (uint256 i; i \u003c ops.length; ++i) {\n            (address to, uint256 value, bytes memory data) = abi.decode(ops[i], (address, uint256, bytes));\n            (bool ok, ) = to.call{value: value}(data);\n            require(ok, \"op failed\");\n        }\n        return \"\";\n    }\n}\n```\n\n## 알아둘 점\n\n- **상태: Draft.** 본문의 일부는 미완성입니다(예를 들어 권장되는 재진입 방어 목록이 비어 있습니다).\n- 보안은 선택한 `IStandard`와 `IAccount` 코드에 달려 있습니다. 둘 다 공개되고 감사를 받아야 하며, EOA 소유자는 신뢰할 수 있는 구현에만 위임해야 합니다.\n- 무상태 계정 코드를 강력히 권장합니다. 위임된 EOA는 가리키는 코드가 무엇이든 그 사이에서 스토리지를 공유하므로, 저장된 상태가 충돌하거나 악용될 수 있기 때문입니다.\n- 명세의 레퍼런스 구현은 설명용입니다. 그대로 배포하지 말고 신중하게 검토하세요.\n- EOA의 개인 키는 여전히 완전한 제어권을 가집니다. 위임을 해제하면 모든 스마트 계정 동작이 비활성화됩니다.\n"},"zh":{"lang":"zh","tldr":"面向通过 EIP-7702 委托代码的 EOA 的极简智能账户接口：所有者签署一个打包的意图，任何求解者或中继者都可以提交，由可插拔的\"standard\"合约验证并将其展开为一系列调用。","tags":["account-abstraction","intents","eip-7702","eoa","gas-sponsorship","draft"],"related":[7702,4337,7521,6900,7579],"updated":"2026-10-19","url":"https://eips.huatuo.xyz/zh/eip-7806/","markdown":"## 它解决什么问题？\n\n账户抽象带来了批量处理、gas 代付和灵活的访问控制。[ERC-4337](/eip-4337/) 实现了这些，但组成部分很多（账户、EntryPoint、paymaster、bundler，以及 [ERC-6900](/eip-6900/) 和 [ERC-7579](/eip-7579/) 等插件标准），每个 `UserOperation` 的 gas 相对较高，升级需要协调，实际使用中还依赖 paymaster 和 bundler。\n\n[EIP-7702](/eip-7702/) 让普通 EOA 可以指向合约代码。ERC-7806 利用这一点，本着 [ERC-7521](/eip-7521/) 的精神，为 EOA 提供一个刻意保持小巧的、**以意图为中心**的智能账户接口：用户签署的是*应该发生什么*，由求解者/中继者组成的开放市场去执行，他们可以用 ETH 支付 gas，再从账户中以代币获得补偿。\n\n## 它如何运作\n\n**UserIntent。** 一个打包的 `bytes` 数据块，包含五个逻辑部分：\n\n| 字段 | 含义 |\n| --- | --- |\n| `sender` | 该意图所属的 EOA |\n| `standard` | 知道如何解读该意图的 `IStandard` 合约的地址 |\n| `header` | 元数据，例如 nonce 或过期时间，由 standard 解释 |\n| `instructions` | 要做什么，例如 `(to, value, calldata)` 条目或代币支出上限 |\n| `signatures` | standard 检查的签名（不一定全部来自所有者） |\n\n建议的编码是 `sender (20) ‖ standard (20) ‖ three uint16 lengths ‖ header ‖ instructions ‖ signatures ‖ extra`，但每个 standard 可以自行定义。\n\n**两个接口。**\n\n- `IStandard.validateUserIntent(bytes) → bytes4` 和 `IStandard.unpackOperations(bytes) → (bytes4, bytes[])`。standard 持有验证规则，就像一个精简版的 EntryPoint。\n- `IAccount.executeUserIntent(bytes) → bytes`。由 EOA 委托的代码实现；它请 standard 验证并展开，然后以 EOA 的身份执行这些操作，因此下游的 `msg.sender` 就是 EOA 本身。\n\n**Gas 抽象。** 任何人都可以提交交易。意图可以让账户用任意代币向提交者（`tx.origin`）付款，所以用户永远不需要为 gas 持有 ETH。求解者还可以把许多意图打包进一笔交易。\n\n重放保护**不是**全局的：由各个 standard 自行决定（一次性哈希、nonce、过期时间），因为有些意图本来就是要重复执行的。\n\n## 示例代码\n\n一个只信任单个 standard 的极简无状态账户（Solidity，仅作演示）：\n\n```solidity\n// SPDX-License-Identifier: MIT\npragma solidity ^0.8.20;\n\ninterface IStandard {\n    function validateUserIntent(bytes calldata intent) external view returns (bytes4);\n    function unpackOperations(bytes calldata intent) external view returns (bytes4, bytes[] memory);\n}\n\ncontract MinimalIntentAccount {\n    bytes4 constant APPROVED = 0x00000001;\n    IStandard public immutable standard; // code is shared; no per-EOA storage\n\n    constructor(IStandard s) { standard = s; }\n\n    function executeUserIntent(bytes calldata intent) external returns (bytes memory) {\n        require(address(bytes20(intent[0:20])) == address(this), \"wrong sender\");\n        require(address(bytes20(intent[20:40])) == address(standard), \"unknown standard\");\n\n        (bytes4 code, bytes[] memory ops) = standard.unpackOperations(intent);\n        require(code == APPROVED, \"rejected\");\n\n        for (uint256 i; i \u003c ops.length; ++i) {\n            (address to, uint256 value, bytes memory data) = abi.decode(ops[i], (address, uint256, bytes));\n            (bool ok, ) = to.call{value: value}(data);\n            require(ok, \"op failed\");\n        }\n        return \"\";\n    }\n}\n```\n\n## 需要注意\n\n- **状态：Draft。** 文本的部分内容尚未完成（例如推荐的重入防护列表是空的）。\n- 安全性取决于所选的 `IStandard` 和 `IAccount` 代码。两者都应公开并经过审计，EOA 所有者只能委托给可信的实现。\n- 强烈建议使用无状态的账户代码：被委托的 EOA 会在其指向的各种代码之间共享存储，因此存储的状态可能冲突或被滥用。\n- 规范中的参考实现仅作演示；请仔细审查，而不要原样部署。\n- EOA 的私钥仍然拥有完全控制权；取消委托会禁用所有智能账户行为。\n"}}}
