iancoleman / bip39

A web tool for converting BIP39 mnemonic codes
https://iancoleman.io/bip39/
MIT License
3.52k stars 1.44k forks source link

multisig / BIP45 recovery #439

Open peanut-brittle opened 4 years ago

peanut-brittle commented 4 years ago

Hi all. I am trying to recover coins forked off Bitcoin from a Copay wallet backup. (I do not have the recovery phrase.) Copay has a recovery tool for Bitcoin forks, but it only does BCH and BSV, and it won't even run correctly for BSV. Bitpay support directed me here, but I'm not sure how to generate the addresses I need or if that's even possible with the available tools.

In my wallet backup I have the xprv, "walletprivkey" which seems to be in hex, and other data that i'm not sure is of use here. It says the derivation strategy is BIP45. The BIP39 tool doesn't seem to generate BIP45 addresses, and the multisig tool doesn't accept xprv keys. Is there a way I can generate correct addresses from my wallet backup? Or some other way to recover the forked coins? I appreciate any advice. I know this isn't really an "issue" with the BIP39 tool so apologies for that.

wigy-opensource-developer commented 4 years ago

I have never used copay and have just skimmed through the BIP45 specification and have a tip that might work for you.

In theory the page now generated you WIF-s in the Private Key column for all receive addresses in the copay wallet. You might want to redo the same steps for different cosigner indexes. Remember, it is just a calculator, you just have to find out the right inputs to it. And your coins are on the chain still.

peanut-brittle commented 4 years ago

Thank you for the idea. I followed your instructions, except I used m/45'/1/0 because I am cosigner 1. (The copay wallet program is multisig but I am the only signer of this wallet.) I selected BTC as the fist coin to try because it's easier for me to check whether the generated addresses are correct or not. So far the results are incorrect. I'm not sure what went wrong, but I can say that all of my real BTC addresses in the wallet begin with 3 and the ones I just created from this all begin with 1.

wigy-opensource-developer commented 4 years ago

Yeah, this gets a bit interesting, because that address is actually a fingerprint of the script with which you prove this coin is yours. This site will not create the proper multipayment script for you, so you can only use the private key from it. But you mentioned another tool you try to do the multisig script, so you might have luck to check the addresses that tool generates based on your private key.

Sounds weird for non-nerds, but you can get lots of different addresses from the same private key using different script templates.