Repository navigation
docs(adr): retire ADR 024 ERC-7579 session-key production plan (#1848) - #2092
Conversation
The Production session-key plan (Safe-7579 adapter + erc7579/smartsessions + off-chain ERC-1271 branch) has no live consumer, no code footprint, and its buyer-side motivation is superseded by ADR 003 capability delegation. Retire it and record the operator-custody residual as unimplemented. ADR 024 keeps the shipped `SignatureChecker` on-chain decision and the EOA-recovery-only off-chain posture as present-tense canon, and gains an "Unimplemented — Operator Custody While Serving" section. That section records why mainnet will likely want a Safe-custodied node that serves from a hot key, and why the obvious ERC-1271 route is unsound for slash-critical signing: ERC-1271 validity is mutable and operator- controlled, so a signature re-verified later as slash evidence can be made invalid after payment (selective validator, post-payment revocation), DoS'd via a gas-bomb validator, or wrongly cached from an off-chain RPC. The recorded direction is a native EOA operator-signer delegation that mirrors the ADR 003 buyer capability, keeping slash_sig EOA-recovered. Dependents updated in the same change so none still assert the retired plan: ADR 012 client key-custody rows and lifecycle, ADR 019 wallet bullet, ADR 003 ephemeral-binding note, appendix-operator-key-rotation (third "slash-sig session key" and its rotation procedures removed), architecture.md ADR 024 summary, and the RotateKeyTarget doc note plus the off-chain-verification section references in protocol/incentive. Co-Authored-By: Claude Opus 4.8 <[email protected]>
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Some references and verification claims are inconsistent with the “retired” posture (e.g., remaining old ADR 024 anchor/title references and repo-wide sweep discrepancies) and should be corrected before approval.
Get a fresh assessment by requesting another Copilot review.
Review effort: Lite
Findings: 3
Open (3)
What changed in this PR
This PR retires ADR 024’s previously “Production” plan for ERC-7579 session keys / off-chain ERC-1271 verification, and updates the surrounding ADRs and inline code docs to reflect the now-canonical posture: on-chain signatures support ERC-1271 via SignatureChecker, while off-chain verification remains EOA-recovery-only, with the remaining operator-custody-while-serving problem explicitly recorded as unimplemented.
Changes:
- Reframes ADR 024 to remove the session-key Production plan, adds an explicit “Unimplemented — Operator Custody While Serving” section, and renames the off-chain verification section to “EOA Recovery Only”.
- Updates dependent ADRs/runbooks to remove the retired “third key/session key” operator rotation path and align buyer-side custody with ADR 003 capability delegation.
- Updates/adjusts multiple Rust doc comments to point at the renamed ADR 024 off-chain verification section (noting a few remaining references still need cleanup).
| File | Description |
|---|---|
| crates/protocol/src/message.rs | Updates ADR 024 section references in validation error docs (some remaining references still point at the old heading). |
| crates/protocol/src/client.rs | Updates voucher/binding signature length docs to cite the renamed ADR 024 off-chain verification section. |
| crates/incentive/src/bind_sig.rs | Reframes bind-signature verification docs to “EOA recovery only” and removes the “deferred ERC-1271 branch” posture (one inline comment still needs alignment). |
| crates/common/src/cli/node.rs | Updates RotateKeyTarget docs to reflect only two operator keys and points to the new unimplemented operator-custody section. |
| adr/architecture.md | Updates ADR 024 summary and operator key-rotation runbook description to match the retired plan. |
| adr/appendix-operator-key-rotation.md | Removes session-key rotation and rewrites the operator rotation decision tree for the two-key posture + optional Safe owner rotation. |
| adr/024-account-abstraction.md | Core retirement/refactor: removes the Production session-key plan, renames off-chain verification section, and records operator-custody residual + ERC-1271 hazards. |
| adr/019-node-onboarding.md | Updates onboarding wallet guidance to remove the session-key/paymaster path and point at the unimplemented operator-custody residual. |
| adr/012-client.md | Updates client key custody narrative/tables to capability-delegated hot EOA signer; removes session-key “Production plan” framing. |
| adr/003-payments.md | Updates off-chain binding text to align smart-account funding with capability-delegated EOA signer + the renamed ADR 024 section. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Review follow-up: - crates/protocol/src/message.rs: InvalidSlashSigLen's doc still cited the old "§Off-Chain ERC-1271 Verification" title; the first pass missed it because the citation is line-wrapped. Retarget to the renamed section. - contracts/test/Token.t.sol: the EIP-2612 Permit section header cited a retired "ADR 024 / ERC-4337 + ERC-1271 path"; gas abstraction (ERC-4337) lives in ADR 003, so cite that. - CHANGELOG.md: add the required one-entry-per-PR record of the retirement under Unreleased § Removed. The prior entry that deferred the off-chain verifier stays as history. Co-Authored-By: Claude Opus 4.8 <[email protected]>
Gas snapshotNo gas changes vs base. |
Contracts coverageLine coverage: 90.63% (2399/2647 lines) |
Coverage reportTotal: 83.36% (was 82.86%, ▲ +0.50%) — 84358/101195 lines
History
|

Closes #1848.
What this decides
ADR 024 deferred high-frequency signing to a Production plan built on the Safe-7579 adapter +
erc7579/smartsessionssession keys, plus an off-chain ERC-1271 verification branch. The reality check the issue asked for: that plan has no live consumer, no code footprint (only prose and doc-comments referenced it), and its buyer-side motivation is fully superseded by ADR 003 capability delegation (#1824). It is retired.The shipped, load-bearing part of ADR 024 — universal
SignatureCheckeron-chain (inCapacityBond,PaymentPool,SlashJudge,DecdnGovernor) and EOA-recovery-only off-chain verification — stays as present-tense canon. Only the design-ahead Production session-key plan is removed.The residual, recorded not built
A node's serving identity is its fund-holding identity (
registerNodebindsmsg.sender,slash_sigis verified by recovery against it), so unlike a client an operator can't separate a hot serving key from multisig-custodied funds via capability delegation. Mainnet will likely want this. ADR 024 gains an "Unimplemented — Operator Custody While Serving" section that records the requirement and the constraints, but commits to no implementation.The core finding: ERC-1271 validity is mutable and operator-controlled, which partitions every deCDN signature:
SignatureCheckeralready does.slash_sig) — ERC-1271 is unsound, because the operator controls validity in the gap between taking payment and the on-chain slash.Four concrete hazards a future design must answer are documented inline: selective validator (valid for serve digests, invalid for the slash-evidence digests), post-payment revocation (the "first-class revocation" a session-key module sells is the attack), gas-bomb on the slash path (
SignatureCheckercaps no gas on the ERC-1271 call), and unsound off-chain RPC evidence (validity is mutable after the block it was read at). The recorded direction is a native EOA operator-signer delegation mirroring the ADR 003 buyer capability — keepingslash_sigEOA-recovered — not an ERC-7579 session key.Dependents updated in the same PR
So none still assert the retired plan:
RotateKeyTargetdoc note, plus the renamed off-chain-verification section references incrates/protocolandcrates/incentive(comment-only).Verification
cargo check(protocol, incentive, common),cargo clippy,cargo doc,cargo fmt --check,markdownlint— all pass (pre-commit hooks ran on commit).smartsessions/7579/paymaster/old section anchors is clean outside the deliberate mentions in the new Unimplemented section.ADR 024 status stays Draft (the operator-custody piece remains open).
🤖 Generated with Claude Code