Author

Topic: Is Bitcoin Wallet for Android Hierarchical Deterministic? (Read 3644 times)

newbie
Activity: 1
Merit: 0
Yes it is since v4.0.

I think Andreas will expose the seed words at some point. Not sure what the delay is.
legendary
Activity: 1456
Merit: 1081
I may write code in exchange for bitcoins.
You can just use the WalletTool program from the bitcoinj source code with a wallet file.

Andreas told me he wants to be careful about exposing the seed words because it can break in various edge cases e.g. if you have an old wallet that has pre-HD keys in it and then you think all you need are the post-HD seed words. So it will take some effort and testing to get it fully right.

I know Mike is out of the scene now, but I need some help with this.  I have pulled my keys from version of the android wallet which was available in Nov 2013.  The keys when backed up came from a newer version of the android wallet in Nov 2014 and I need to get the private key for my original address that was reused a bunch before this wallet went to HD.  I have the seed which says it had a birthday on Nov 14, 2013, but after putting the seed into an HD wallet generator like the one mentioned above  (https://dcpos.github.io/bip39/) I cannot generate the same original address/key pair.  Does anyone have some clues to figure out how to get the private key for the original address?

Three keys came out in a format like this:

Keys:
addr:xxxxxx...
hash160:xxxxxx...
ECKey{pub=xxxxxx...,
priv=xxxxxx...
creationTimeSeconds=xxxxxx, isEncrypted=false, isPubKeyOnly=false}


And then this once:

Seed as words: xxxx xxxx xxxx ...
Seed as hex: xxxxxx...
Seed Birthday : xxxxxx.
Key to watch: xxxxxx...
addr: xxxxxx...
hash160:xxxxxx...



And then a few more like this:

DeterministicKey{pub=xxxxxx...,
priv=xxxxxx..., isEncrypted=false, isPubKeyOnly=true}
addr:xxxxxx...



I've also tried to used the ECKeys to generate WIF format private keys, but they do not produce the original address.

Thanks in advance!

Moreover the very first address on this decrypted list is the address I need, but like I said I could not get the ECKeys to produce the right WIF format.

I'm not sure if I understand correctly.  Is it the case that you have the public/private key pair for the addy you want?  And that your issue is just converting the format to WIF?  If so, it's not that hard, I can probably help you.  What format are the keys in now (hex, binary, decimal)?

I have a python script which takes a private key as input and produces the bitcoin addresses and WIF for the priv keys for that private key.

Yes, I have the public and private key pair written as "ECKey{pub=[key here], priv=[key here]}.  It appears to be hexadecimal.  This is straight from the instructions of extracting private keys from the Schildbach wallet key file.



We chatted a bit in PM, but it might be helpful to others to put this here.  Given the priv key in hex, you should be able to convert it to all the other formats with the 'ku'  program which is part of pycoin:

https://github.com/richardkiss/pycoin

I went through the same process you did some time ago, exporting a particular address from a wallet backup and needing the WIF in order to use it elsewhere.
newbie
Activity: 45
Merit: 0
You can just use the WalletTool program from the bitcoinj source code with a wallet file.

Andreas told me he wants to be careful about exposing the seed words because it can break in various edge cases e.g. if you have an old wallet that has pre-HD keys in it and then you think all you need are the post-HD seed words. So it will take some effort and testing to get it fully right.

I know Mike is out of the scene now, but I need some help with this.  I have pulled my keys from version of the android wallet which was available in Nov 2013.  The keys when backed up came from a newer version of the android wallet in Nov 2014 and I need to get the private key for my original address that was reused a bunch before this wallet went to HD.  I have the seed which says it had a birthday on Nov 14, 2013, but after putting the seed into an HD wallet generator like the one mentioned above  (https://dcpos.github.io/bip39/) I cannot generate the same original address/key pair.  Does anyone have some clues to figure out how to get the private key for the original address?

Three keys came out in a format like this:

Keys:
addr:xxxxxx...
hash160:xxxxxx...
ECKey{pub=xxxxxx...,
priv=xxxxxx...
creationTimeSeconds=xxxxxx, isEncrypted=false, isPubKeyOnly=false}


And then this once:

Seed as words: xxxx xxxx xxxx ...
Seed as hex: xxxxxx...
Seed Birthday : xxxxxx.
Key to watch: xxxxxx...
addr: xxxxxx...
hash160:xxxxxx...



And then a few more like this:

DeterministicKey{pub=xxxxxx...,
priv=xxxxxx..., isEncrypted=false, isPubKeyOnly=true}
addr:xxxxxx...



I've also tried to used the ECKeys to generate WIF format private keys, but they do not produce the original address.

Thanks in advance!

Moreover the very first address on this decrypted list is the address I need, but like I said I could not get the ECKeys to produce the right WIF format.

I'm not sure if I understand correctly.  Is it the case that you have the public/private key pair for the addy you want?  And that your issue is just converting the format to WIF?  If so, it's not that hard, I can probably help you.  What format are the keys in now (hex, binary, decimal)?

I have a python script which takes a private key as input and produces the bitcoin addresses and WIF for the priv keys for that private key.

Yes, I have the public and private key pair written as "ECKey{pub=[key here], priv=[key here]}.  It appears to be hexadecimal.  This is straight from the instructions of extracting private keys from the Schildbach wallet key file.

legendary
Activity: 1456
Merit: 1081
I may write code in exchange for bitcoins.
You can just use the WalletTool program from the bitcoinj source code with a wallet file.

Andreas told me he wants to be careful about exposing the seed words because it can break in various edge cases e.g. if you have an old wallet that has pre-HD keys in it and then you think all you need are the post-HD seed words. So it will take some effort and testing to get it fully right.

I know Mike is out of the scene now, but I need some help with this.  I have pulled my keys from version of the android wallet which was available in Nov 2013.  The keys when backed up came from a newer version of the android wallet in Nov 2014 and I need to get the private key for my original address that was reused a bunch before this wallet went to HD.  I have the seed which says it had a birthday on Nov 14, 2013, but after putting the seed into an HD wallet generator like the one mentioned above  (https://dcpos.github.io/bip39/) I cannot generate the same original address/key pair.  Does anyone have some clues to figure out how to get the private key for the original address?

Three keys came out in a format like this:

Keys:
addr:xxxxxx...
hash160:xxxxxx...
ECKey{pub=xxxxxx...,
priv=xxxxxx...
creationTimeSeconds=xxxxxx, isEncrypted=false, isPubKeyOnly=false}


And then this once:

Seed as words: xxxx xxxx xxxx ...
Seed as hex: xxxxxx...
Seed Birthday : xxxxxx.
Key to watch: xxxxxx...
addr: xxxxxx...
hash160:xxxxxx...



And then a few more like this:

DeterministicKey{pub=xxxxxx...,
priv=xxxxxx..., isEncrypted=false, isPubKeyOnly=true}
addr:xxxxxx...



I've also tried to used the ECKeys to generate WIF format private keys, but they do not produce the original address.

Thanks in advance!

Moreover the very first address on this decrypted list is the address I need, but like I said I could not get the ECKeys to produce the right WIF format.

I'm not sure if I understand correctly.  Is it the case that you have the public/private key pair for the addy you want?  And that your issue is just converting the format to WIF?  If so, it's not that hard, I can probably help you.  What format are the keys in now (hex, binary, decimal)?

I have a python script which takes a private key as input and produces the bitcoin addresses and WIF for the priv keys for that private key.
newbie
Activity: 45
Merit: 0
You can just use the WalletTool program from the bitcoinj source code with a wallet file.

Andreas told me he wants to be careful about exposing the seed words because it can break in various edge cases e.g. if you have an old wallet that has pre-HD keys in it and then you think all you need are the post-HD seed words. So it will take some effort and testing to get it fully right.

I know Mike is out of the scene now, but I need some help with this.  I have pulled my keys from version of the android wallet which was available in Nov 2013.  The keys when backed up came from a newer version of the android wallet in Nov 2014 and I need to get the private key for my original address that was reused a bunch before this wallet went to HD.  I have the seed which says it had a birthday on Nov 14, 2013, but after putting the seed into an HD wallet generator like the one mentioned above  (https://dcpos.github.io/bip39/) I cannot generate the same original address/key pair.  Does anyone have some clues to figure out how to get the private key for the original address?

Three keys came out in a format like this:

Keys:
addr:xxxxxx...
hash160:xxxxxx...
ECKey{pub=xxxxxx...,
priv=xxxxxx...
creationTimeSeconds=xxxxxx, isEncrypted=false, isPubKeyOnly=false}


And then this once:

Seed as words: xxxx xxxx xxxx ...
Seed as hex: xxxxxx...
Seed Birthday : xxxxxx.
Key to watch: xxxxxx...
addr: xxxxxx...
hash160:xxxxxx...



And then a few more like this:

DeterministicKey{pub=xxxxxx...,
priv=xxxxxx..., isEncrypted=false, isPubKeyOnly=true}
addr:xxxxxx...



I've also tried to used the ECKeys to generate WIF format private keys, but they do not produce the original address.

Thanks in advance!

Moreover the very first address on this decrypted list is the address I need, but like I said I could not get the ECKeys to produce the right WIF format.
newbie
Activity: 45
Merit: 0
You can just use the WalletTool program from the bitcoinj source code with a wallet file.

Andreas told me he wants to be careful about exposing the seed words because it can break in various edge cases e.g. if you have an old wallet that has pre-HD keys in it and then you think all you need are the post-HD seed words. So it will take some effort and testing to get it fully right.

I know Mike is out of the scene now, but I need some help with this.  I have pulled my keys from version of the android wallet which was available in Nov 2013.  The keys when backed up came from a newer version of the android wallet in Nov 2014 and I need to get the private key for my original address that was reused a bunch before this wallet went to HD.  I have the seed which says it had a birthday on Nov 14, 2013, but after putting the seed into an HD wallet generator like the one mentioned above  (https://dcpos.github.io/bip39/) I cannot generate the same original address/key pair.  Does anyone have some clues to figure out how to get the private key for the original address?

Three keys came out in a format like this:

Keys:
addr:xxxxxx...
hash160:xxxxxx...
ECKey{pub=xxxxxx...,
priv=xxxxxx...
creationTimeSeconds=xxxxxx, isEncrypted=false, isPubKeyOnly=false}


And then this once:

Seed as words: xxxx xxxx xxxx ...
Seed as hex: xxxxxx...
Seed Birthday : xxxxxx.
Key to watch: xxxxxx...
addr: xxxxxx...
hash160:xxxxxx...



And then a few more like this:

DeterministicKey{pub=xxxxxx...,
priv=xxxxxx..., isEncrypted=false, isPubKeyOnly=true}
addr:xxxxxx...



I've also tried to used the ECKeys to generate WIF format private keys, but they do not produce the original address.

Thanks in advance!
legendary
Activity: 1526
Merit: 1134
You can just use the WalletTool program from the bitcoinj source code with a wallet file.

Andreas told me he wants to be careful about exposing the seed words because it can break in various edge cases e.g. if you have an old wallet that has pre-HD keys in it and then you think all you need are the post-HD seed words. So it will take some effort and testing to get it fully right.
hero member
Activity: 793
Merit: 1026
Thanks man, I appreciate that!
hero member
Activity: 672
Merit: 504
a.k.a. gurnec on GitHub
Yes it is since v4.0.

I think Andreas will expose the seed words at some point. Not sure what the delay is.

Is there *any* method of getting at the seed from the application's data files?  I don't want to use it unless I've backed up the seed myself, and currently I don't know how to do that.

I went ahead and wrote a python script which can extract the seed from either a backup file or from the raw wallet file (which you can only get to if your phone is rooted). Feel free to give it a try, instructions and download links are at GitHub: https://github.com/gurnec/decrypt_bitcoinj_seed. You'll of course need your backup password (if it's a wallet backup file) and your PIN, if any.

I've verified that the seed I get from the script can be used to generate the same sequence of addresses/keys as are in the app (I just went here and plugged in my seed -- obviously if you choose to do something similar with anything but a test seed, you should use an offline copy of that page).
hero member
Activity: 793
Merit: 1026
Yes it is since v4.0.

I think Andreas will expose the seed words at some point. Not sure what the delay is.

Is there *any* method of getting at the seed from the application's data files?  I don't want to use it unless I've backed up the seed myself, and currently I don't know how to do that.
full member
Activity: 209
Merit: 100
Thanks for clearing that up.
legendary
Activity: 1526
Merit: 1134
Yes it is since v4.0.

I think Andreas will expose the seed words at some point. Not sure what the delay is.
full member
Activity: 209
Merit: 100
Just wondering if Bitcoin Wallet for Android is Hierarchical Deterministic or not.
It's not completely obvious to me since it doesn't offer seed backup.

If it isn't HD, what are its methods of private key generation?

Thanks ahead of time.
Jump to: