wallet (epic): BIP32/39/44 HD wallets — primitives in tree, no wiring #35
Labels
No labels
enhancement
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
SubGeniusFinance/Offerings-to-Cthulhu#35
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Goal
Wire OFF's wallet to use the BIP32 hierarchical-deterministic key-derivation primitives that already sit in the codebase, add BIP39 mnemonic-seed import/export, and standardize derivation paths via BIP44. Replace the legacy "100-key keypool, refill when low" model inherited from Bitcoin Core 0.10.
This is a multi-PR epic, not a single change. Tracked here as the umbrella for future scoped sub-issues. No fork height needed — wallet-only, no consensus change.
Flagged by @9019x on 2026-06-14: "framework already mostly in place on 0.10 — but not used."
Current state
What exists in tree but is unused:
src/key.h:267-306—CExtKey,CExtPubKeyclasses withDerive()/Neuter()methods. BIP32 primitives, fully implemented.src/base58.h:156-157—CBitcoinExtKey/CBitcoinExtPubKey(xprv/xpub base58 encodings).What's missing:
CExtKey::Derive()insrc/wallet.cpp. Wallet still uses the legacyCKeyPoolrandom-key model.HDChainstruct inwallet.{h,cpp}, no wallet record-version bump, no seed storage path.MnemonicToSeed()PBKDF2 helper, no UI for restore-from-phrase.Why this is NOT in the v2.0.x consensus-fork bundle
Wallet feature, not consensus. No fork height, no chain-split risk, no activation coordination. Different release cadence (
v2.1.xorv2.2.x, notv2.0.x). Different test surface (wallet upgrade tests, mnemonic round-trip tests — not consensus regression vectors). Different failure mode (one user's wallet has issues vs the chain forks).Folding it into the BIP66 / BIP65 / COINBASE_MATURITY release would couple unrelated risks. Kept explicitly separate per discussion 2026-06-15.
Scope breakdown (future sub-issues)
This epic should fan out into roughly:
satoshilabs/slipspicking an OFF coin-type number. Blocking dependency for BIP44.CExtKey::Derive()intoCWallet. Wallet record-version bump. Backward-compat handling for legacy keypool. ~500 LoC.dumpmnemonic+ CLI restore. ~300 LoC.m/44'/<OFF-coin-type>'/0'/{0,1}/i. Depends on (1).Design questions for later discussion
References
src/key.h:267-306— existingCExtKey/CExtPubKeyprimitivessrc/base58.h:156-157— existing extended-key base58 wrapperssrc/wallet.cpp— legacy keypool model (no HD calls)Community chat: https://23skidoo.info/discord