Repository navigation
Description
Decision (2026-07 ADR simplification audit). Filed under the Protocol simplifications milestone — sibling to #1396, #1394, #1419. Verdict: DROP the off-chain ERC-1271 + Safe-as-wallet surface. Keep the contract-level
SignatureCheckeras insurance. A simpler "publisher pays" replacement (session-key funded vouchers, with rate-limiting + fund-theft defenses) is designed separately — linked below once filed.
Drop proposal: node-side off-chain ERC-1271 verification + "Safe as recommended wallet" (ADR 024)
Status: proposal for discussion, not a decision.
Summary
ADR 024 bundles three things under "Account Abstraction and Safe Smart Wallet Support":
- Contract-level
SignatureCheckeracross every verification site — already merged, cheap, no retrofit later. Keep. - "Safe as the recommended wallet" for node operators and clients, plus the operator setup tooling (
decdn setupguiding Safe creation) that this recommendation implies. By the ADR's own words a PoC 1-of-1 Safe is "the same trust posture as today'seth_keystore" — zero security gain, added setup burden. - Node-side Rust off-chain ERC-1271 verification — a
get_code_atRPC round-trip per client connection plus a code cache, to validate smart-account clients. Never built; explicitly deferred in the code. The client type it serves barely exists, and the feature that would make it usable end-to-end (session keys) is itself deferred to Production.
This proposal drops (2) and (3) from the PoC surface of ADR 024, keeps (1) as insurance, and keeps the Production session-key design as documented-and-deferred. The two drop targets are separable and are argued separately below.
Motivation
-
A 1-of-1 Safe buys zero security over an EOA keystore — the ADR says so. ADR 024 §18 and §Safe-as-Recommended-Wallet: "The single owner is a software-held key on the signing host — same trust posture as today's
eth_keystore." Recommending it, and buildingdecdn setuptooling to guide Safe creation (ADR 024 §Consequences: "Safe wallet setup is more complex than generating an EOA. Operator tooling must guide Safe creation"), adds operator onboarding friction for no PoC security benefit. This is scale-independent: a 1-of-1 Safe never buys security over its own single owner key, at any network size. -
The ADR itself rules out multisig on the hot path in the PoC. The real security argument for "Safe" is 2-of-3 multisig (Motivation 2). But ADR 024 §Node Operators explicitly forbids it for the PoC: "2-of-3 is not recommended for the PoC because
SignatureChecker→ Safe'scheckSignaturescannot reach a multi-owner threshold at wire speed." Multisig only helps on the infrequent stake/withdraw/channel-open (cold) paths — and an operator who wants that can already pointmsg.senderat a Safe on those paths with no deCDN "recommendation" and no tooling, because the retained contract-levelSignatureCheckermakes it transparent. So the recommendation delivers nothing the retained piece doesn't already enable. -
The node-side ERC-1271 path was never built and can't be exercised end-to-end in the PoC. Grep confirms zero implementation: no
get_code_at, noisValidSignatureRPC call, noERC1271_MAGICanywhere incrates/. Every off-chain verifier (bind_sig.rs,channel.rs,probe_sig.rs) is EOA-only (fixed 65-byter‖s‖v) and fail-closed against smart-account signatures, each citing ADR 024 as deferred. Worse, even if it were built, a PoC smart-account client signing vouchers with its Safe owner key hits exactly the per-MB-cadence hot-signing problem the ADR flags as infeasible without session keys — and session keys are deferred to Production. So the node-side path would let a Safe client bind but not sustainably pay in the PoC: a half-feature with no working end-to-end path. -
Deferring the node-side path is low-risk because it's node-side, not a contract. The expensive, coordinated retrofit ADR 024 rightly worries about is the contract one (every verification site, every deployed contract, migrate in lockstep). That is precisely the piece we keep and that already shipped. The Rust ERC-1271 path is a pure additive change to node software: it can land whenever smart-account clients actually arrive, verify against the already-deployed
SignatureCheckercontracts, and roll out node-by-node with no coordinated migration. Nothing about dropping it now makes adding it later harder. -
Bias to low operator barriers. Recommending Safe and shipping Safe-setup tooling pushes every operator toward a more complex onboarding for a PoC-null benefit. The cheap-entry default should be "generate an EOA keystore"; a Safe remains fully usable for anyone who wants one, because the contracts already accept it.
What removal touches
Blast radius. The node-side Rust path and the Safe-setup tooling are the removals; the contract-level SignatureChecker is retained, so most doc edits are trims/relabels rather than deletions.
ADRs / docs
adr/024-account-abstraction.md— the primary edit. Keep §UniversalSignatureCheckerin All Contracts (retained, already implemented) and the §Session Keys Production plan (documented-deferred). Remove/relabel §Safe as Recommended Wallet (down to: "Safe and any ERC-1271 wallet work at the contract level; deCDN recommends and tools only the EOA keystore for the PoC") and §Off-Chain ERC-1271 Verification (relabel from PoC deliverable to Production-deferred, matching what the code already says). Drop thedecdn setupSafe-guidance obligation from §Consequences.adr/012-client.md— §Session/step 4 currently says the node verifies "ERC-1271isValidSignatureRPC call for smart account clients"; relabel that as deferred (the code is EOA-only). PoC key-management lines that offer "file-based EOA or Safe wallet" should lead with EOA. Session-key references stay (Production).adr/003-payments.md— line ~926 (ephemeral binding) says the node verifies via "an RPC call toisValidSignaturefor smart account clients"; relabel deferred. The §54 contract-levelSignatureCheckertext stays. "Safe … are the recommended wallet type" phrasing softens to "supported."adr/016-contract-interactions.md(canonical contract surface) — line 737SignatureCheckerrow stays as-is; it documents the retained piece. No change beyond the ADR 024 link target if that section is relabeled.adr/014-on-chain-verification.md—SignatureCheckergas notes stay (on-chain path retained); only the ADR 024 anchor may shift.adr/019-node-onboarding.md,adr/appendix-operator-key-rotation.md,adr/appendix-operator-upgrade-path.md,adr/architecture.md(lines 81, 164),adr/glossary.md— cross-references to ADR 024's Safe/session-key framing; trim to match the retained-contract + deferred-node-path shape. Session-key rotation content stays (Production).website/docs/overview/design-decisions.mdx— public-facing account-abstraction claim; align with whatever the ADR lands on. Nothing here is a source of truth.
Rust node verification path
- No code to delete — the path was never built. The change is comment cleanup so the code stops implying a PoC obligation it never carried: the deferral notes in
crates/incentive/src/bind_sig.rs(module docs +BindErrorvariants),crates/incentive/src/channel.rs:347-353,crates/protocol/src/message.rs:55-65. These already say "deferred (ADR 024)"; they just need to point at whatever the ADR becomes. The EOAecrecoverpath (verify_binding,verify_signer, probe/voucher signing) is untouched.
Contracts — SignatureChecker is RETAINED
- No contract changes.
SignatureCheckerstays wired inPaymentChannel.sol(voucher + provider sig),CapacityBond.sol(registerNode/bindNodeIdbindings),SlashJudge.sol(phantom/rate/blacklist evidence), andDecdnGovernor.sol(EIP-712 delegation). This is the one-line-swap insurance that avoids a coordinated on-chain retrofit; keeping it is free (already merged) and is the whole reason dropping the node-side path is cheap.
Config
- Nothing to remove. There is no Safe/smart-account/wallet config surface today (
crates/common/src/confighas none). Dropping the recommendation means we simply never add Safe-setup config ordecdn setupSafe flows.
Tests
- Contract tests stay —
PaymentChannel.t.sol,Token.t.sol,DecdnGovernorDelegation.t.sol, and theg_gov_03_real_evidence.rse2e all exercise the retained on-chainSignatureCheckerpath. No test removal. - No Rust test removal: there are no node-side ERC-1271 tests (the path doesn't exist).
What we keep
- Contract-level
SignatureCheckerat every verification site (PaymentChannel, CapacityBond, SlashJudge, DecdnGovernor) — already merged, ~one line per site, avoids the expensive coordinated on-chain retrofit if smart accounts ever land. This is the insurance and it costs nothing to keep. - The EOA
ecrecoveroff-chain path — already the only implemented path; no RPC round-trip, no code cache, lowest operator barrier. - Safe as a supported (not recommended, not tooled) wallet — the retained contract-level
SignatureCheckeralready lets any operator or client use a Safe asmsg.sender/channel.clienton the cold paths with no deCDN feature. We simply stop recommending it and stop committing to build setup tooling around it. - The Production session-key design (
Safe-7579+erc7579/smartsessions) as documented-and-deferred future work — it is the real answer to hot-signing and to smart-account clients, and nothing here touches it.
Counter-argument (strongest keep-case)
On (3), the node-side ERC-1271 path — the adoption / account-abstraction angle. [your call]
The honest keep-case is a trajectory argument, not a scale argument: ERC-4337 / smart-account wallets are a real and growing share of Ethereum users, and if deCDN wants to onboard clients who hold funds in a Safe or an AA wallet, the node must be able to verify their off-chain binding signatures — otherwise every smart-account client is un-servable at the door. If that adoption is a near-term goal, then the node-side path is genuinely needed and this becomes a KEEP.
Weighing it honestly, three things pull it back to drop-but-marginal rather than keep:
- The end-to-end path is broken in the PoC regardless. A smart-account client can bind, but signing vouchers at the per-MB cadence with a Safe owner key is the exact infeasibility the ADR flags — it needs session keys, which are Production-deferred. So building the node-side binding verifier now yields a client that can connect but can't sustainably pay. The adoption goal isn't actually met until the deferred session-key work lands anyway.
- It's a node-side, uncoordinated add. Unlike the contract retrofit, this path can ship the day smart-account clients matter, verified against the already-deployed
SignatureCheckercontracts, with no lockstep migration. Deferring it costs nothing at the point of need. - The RPC round-trip + code cache is real complexity (
get_code_atper new client connection, cache invalidation reasoning aroundSELFDESTRUCT) that today has no exercising traffic.
So: keep the contract insurance (which is what makes future smart-account support cheap), defer the node path until a smart-account client actually needs to connect and the session-key path exists to let it pay. If the team decides AA-client onboarding is a committed next-quarter goal, flip (3) to KEEP and schedule it alongside the session-key work rather than as an isolated half-feature.
On (2), "Safe as recommended wallet": there is no real keep-case at PoC. The only security value is multisig, which the ADR itself disallows on the hot path and which the retained contract-level SignatureChecker already enables on the cold paths without any recommendation or tooling. Dropping the recommendation (and the decdn setup Safe-guidance obligation) loses nothing and lowers operator onboarding friction.
Open questions
- Is onboarding smart-account / ERC-4337 clients a committed near-term goal? If yes, (3) is a KEEP and should be scheduled with the session-key module, not deferred open-endedly.
- Should ADR 024 be rewritten in place (retitle to "Universal
SignatureChecker; Safe supported, session keys deferred") or split — retained contract piece folded into ADR 003/016, the deferred node + Safe-recommendation content archived toadr/_history/? - Do we keep any
decdn setupSafe documentation (a how-to for operators who choose a Safe), even though we drop the recommendation and the guided tooling? Low-cost docs vs. an implied support commitment. contracts/lib/soladyand OZ ship ERC-1271 mocks/libs — pure dependency artifacts, no action, but worth confirming none of deCDN's own test suites depend on a node-side ERC-1271 fixture (grep shows they don't).
Metadata
Metadata
Assignees
Labels
Type
Fields
Priority
Activity
alpergundogdu commentedon Jul 24, 2026
Follow-up: the simpler "publisher pays" replacement for this dropped surface is being designed in #1444.
altanoruc commentedon Jul 24, 2026
Automated implementation triage note for a later run: the decision header resolves the product posture, but the docs disposition remains open. Please choose rewrite ADR 024 in place versus archive/fold its retained SignatureChecker content into ADR 003/016, and decide whether any optional Safe operator how-to remains. Once that exact present-tense document shape is pinned, this appears docs-only and dispatchable.