ETH Restore: Mnemonic Recovery Tool
Losing access to an Ethereum wallet is a common and painful failure mode. The wallet is secure by design — if the mnemonic seed phrase is lost or incomplete, the funds are gone. But partial loss is a different problem. When most of the mnemonic is intact and only a few words are missing, recovery is mathematically feasible. The search space is large but bounded.
The problem
A user has an Ethereum wallet they can no longer access. The mnemonic is incomplete — one or more words are missing or uncertain. They know the target wallet address. The challenge is to find the correct missing words, reconstruct a valid mnemonic, derive the Ethereum address, and check whether it matches the target.
A 12-word BIP-39 mnemonic has a 2048-word dictionary. One missing word means up to 2048 candidates. Two missing words means up to 4 million. Three missing words and the space exceeds 8 billion. Sequential search is too slow for anything beyond a single missing word. The problem demands parallelism.
Approach
The tool is built in Python using bip_utils for mnemonic validation and address derivation, with multiprocessing for parallel brute-force search.
The approach is direct: generate candidate mnemonics by filling missing word positions with dictionary words, validate each candidate against the BIP-39 checksum, derive the Ethereum address, and compare to the target. Invalid checksums are rejected immediately — this prunes the search space significantly since most random word combinations fail checksum validation.
bip_utils handles the cryptographic pipeline: mnemonic validation, seed derivation via PBKDF2, BIP-32 master key generation, BIP-44 derivation path for Ethereum (m/44'/60'/0'/0/0), and address computation. This is the standard Ethereum wallet derivation path. The library does the heavy lifting; the tool orchestrates the search.
multiprocessing distributes candidate generation across CPU cores. Each worker takes a slice of the search space, generates candidates, validates, derives, and checks. Results are collected as they are found. A match terminates the search early — once the target address is hit, there is no reason to keep checking.
What was built
The tool provides:
- Automated mnemonic recovery. Given a partial mnemonic with marked missing positions and a target Ethereum address, the tool searches the full candidate space and returns the complete valid mnemonic if a match exists.
- Parallel processing. The search uses all available CPU cores via Python's multiprocessing module. Worker processes handle independent slices of the dictionary space, with near-linear speedup on multi-core machines. What would take hours on a single core finishes in minutes across 8 or 16 workers.
- Checksum validation. Every candidate mnemonic is validated against the BIP-39 checksum before address derivation. This eliminates roughly 93% of candidates immediately — only valid mnemonics proceed to the expensive derivation step.
- Logging and progress tracking. The tool logs search progress, candidates checked, elapsed time, and estimated completion. Long brute-force runs are opaque without this; progress reporting makes it clear the search is advancing and gives a sense of how long remains.
Results
The tool recovers wallets with one or two missing words in practical timeframes on a standard multi-core machine. Single-word recovery completes in seconds. Two-word recovery, with the checksum pruning, typically finishes in minutes rather than hours. The parallel architecture scales with available cores — more cores means proportionally faster search.
The logging and progress tracking turned an opaque batch job into an observable process. Users can see candidates per second, estimated time remaining, and current search position. For a tool that runs for minutes or hours, this is the difference between trusting it is working and wondering if it hung.
Takeaway
Partial mnemonic loss is recoverable when the search space is bounded and the target address is known. The key engineering decisions are straightforward: use a proven library for the cryptography, prune aggressively with checksum validation, and parallelize the search across cores. The tool does not reinvent wallet derivation — it uses bip_utils for that — and focuses its effort on the search orchestration and parallelism that make recovery practical. Security tools do not need to be clever. They need to be correct and fast enough.
