what kind of speed should i expect when using python to brute force 12 word bip39 seed phrase from word list?
Pure Python implementation should get you maybe like a dozen or two per second, that's all.
it shows around 10000h/s
Sounds like you are doing part of the work only. I was testing the whole thing like getting a list of deterministic keys/addresses and so on.
atleast it found test phrase.
now playing with
https://privatekeys.pw/puzzles/0.2-btc-puzzleimport time
import itertools
from multiprocessing import Pool, cpu_count
import hashlib, struct, base58
from ecdsa import SigningKey, SECP256k1
# === Configuration ===
TARGET_ADDRESS = "1KfZGvwZxsvSmemoCmEV75uqcNzYBHjkHZ"
#
position_words = {
1: ["black", "this", "order", "find", "real", "subject", "food", "truth", "hidden", "future", "freedom", "power", "welcome"],
2: ["black", "this", "order", "find", "real", "subject", "food", "truth", "hidden", "future", "freedom", "power", "welcome"],
3: ["black", "this", "order", "find", "real", "subject", "food", "truth", "hidden", "future", "freedom", "power", "welcome"],
4: ["black", "this", "order", "find", "real", "subject", "food", "truth", "hidden", "future", "freedom", "power", "welcome"],
5: ["black", "this", "order", "find", "real", "subject", "food", "truth", "hidden", "future", "freedom", "power", "welcome"],
6: ["black", "this", "order", "find", "real", "subject", "food", "truth", "hidden", "future", "freedom", "power", "welcome"],
7: ["black", "this", "order", "find", "real", "subject", "food", "truth", "hidden", "future", "freedom", "power", "welcome"],
8: ["black", "this", "order", "find", "real", "subject", "food", "truth", "hidden", "future", "freedom", "power", "welcome"],
9: ["black", "this", "order", "find", "real", "subject", "food", "truth", "hidden", "future", "freedom", "power", "welcome"],
10: ["black", "this", "order", "find", "real", "subject", "food", "truth", "hidden", "future", "freedom", "power", "welcome"],
11: ["black", "this", "order", "find", "real", "subject", "food", "truth", "hidden", "future", "freedom", "power", "welcome"],
12: ["black", "this", "order", "find", "real", "subject", "food", "truth", "hidden", "future", "freedom", "power", "welcome"]
}
REPORT_INTERVAL = 5 # seconds
# === Private key to P2PKH address ===
def private_to_address(priv):
sk = SigningKey.from_string(priv, curve=SECP256k1)
pub = b'\x04' + sk.verifying_key.to_string()
sha = hashlib.sha256(pub).digest()
ripe = hashlib.new('ripemd160', sha).digest()
prefixed = b'\x00' + ripe
checksum = hashlib.sha256(hashlib.sha256(prefixed).digest()).digest()[:4]
return base58.b58encode(prefixed + checksum).decode()
# === Electrum v1 seed to address ===
def electrum_seed_to_addr(seed_words):
phrase = ' '.join(seed_words)
seed = hashlib.sha512(phrase.encode('utf-8')).digest()
priv_key = seed[:32]
return private_to_address(priv_key)
# === Combination checker ===
def check_combination(combo):
if len(set(combo)) < len(combo): # enforce unique words
return None
try:
address = electrum_seed_to_addr(combo)
if address == TARGET_ADDRESS:
return combo
except:
return None
return None
# === Parallel combination scanner ===
def scan_combinations_parallel():
word_lists = [position_words[i + 1] for i in range(12)]
total = 1
for lst in word_lists:
total *= len(lst)
print(f"Scanning {total:,} Electrum v1 seed combinations using {cpu_count()} cores...")
start = time.time()
last_report = start
pool = Pool(cpu_count())
generator = itertools.product(*word_lists)
for i, result in enumerate(pool.imap_unordered(check_combination, generator, chunksize=500)):
now = time.time()
if now - last_report >= REPORT_INTERVAL:
elapsed = now - start
speed = i / elapsed
progress = (i / total) * 100
print(f"[{elapsed:.1f}s] Checked: {i:,} | Speed: {speed:,.0f}/s | Progress: {progress:.6f}%")
last_report = now
if result:
print("\nSUCCESS! Valid Electrum seed found:")
print(" ".join(result))
print(f"Address: {TARGET_ADDRESS}")
pool.terminate()
return
print("\nDone. No matching Electrum-style mnemonic found.")
# === Main ===
if __name__ == "__main__":
scan_combinations_parallel()
hopeless:
Scanning 23,298,085,122,481 Electrum v1 seed combinations using 8 cores...
[5.0s] Checked: 5,108,500 | Speed: 1,021,699/s | Progress: 0.000022%
Don’t waste your time on this it’s an endless attempt with near zero chance of success. Thhe creator hasn’t updated or even signed the puzzle address. It’s not worth 0.2 BTC; you’re better off sticking with the 32 BTC puzzle instead.