Bitcoin Forum
November 10, 2024, 04:00:06 PM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Importing private key into Bitcoin Core 0.9.0  (Read 3276 times)
TookDk (OP)
Legendary
*
Offline Offline

Activity: 1960
Merit: 1062


One coin to rule them all


View Profile WWW
April 08, 2014, 09:54:11 AM
 #1

I was wondering about how private keys are stored in wallet.dat.

I use bitcoin core 0.9.0 as my hot-wallet, I have a series of public keys i use for different purposes.

If I import a private key with the command: importprivkey  (e.g. a selfgenerated vainity key)
Will this key just be added to wallet.dat in equal terms as the other private keys, which bitcoin-core has generated?

What happen if this newly imported private key later get compromised? This will compromise funds send to the corresponding public key, right?

I know I have almost answered the questions my self, just want to have a confirmation that I understood the application correct. 

Is there any good know practices about using vanity keys? Should they be also be kept separate from you other keys, or is it find to use bitcoin-core to manage all your private keys?

Cryptography is one of the few things you can truly trust.
Light
Hero Member
*****
Offline Offline

Activity: 742
Merit: 502


Circa 2010


View Profile
April 08, 2014, 10:17:45 AM
 #2

I was wondering about how private keys are stored in wallet.dat.

I use bitcoin core 0.9.0 as my hot-wallet, I have a series of public keys i use for different purposes.

If I import a private key with the command: importprivkey  (e.g. a selfgenerated vainity key)
Will this key just be added to wallet.dat in equal terms as the other private keys, which bitcoin-core has generated?

What happen if this newly imported private key later get compromised? This will compromise funds send to the corresponding public key, right?

I know I have almost answered the questions my self, just want to have a confirmation that I understood the application correct. 

Is there any good know practices about using vanity keys? Should they be also be kept separate from you other keys, or is it find to use bitcoin-core to manage all your private keys?

Yes in Qt it is just the same as the pregenerated ones and any future ones you may generate. If it gets compromised, it is the same as for any other private key, those funds can easily be moved and you'll unfortunately lose access to them. Vanity keys are exactly the same as the keys that are used normally, just that they have been found by bruteforcing private keys to match a specific pattern, so treat them no differently.

On a side note, if you're creating vanity addresses, try and make compressed keys as there is no reason really not to, and they use less space and IIRC they may lead to you needing less tx fees.
TookDk (OP)
Legendary
*
Offline Offline

Activity: 1960
Merit: 1062


One coin to rule them all


View Profile WWW
April 08, 2014, 10:53:53 AM
 #3

I believe I understand Bitcoin-Core correct then.

I have not been experimenting with generating compressed keys yet, but I get the idea about lowering the tx size.

Thanks for the reply, cheers!

Cryptography is one of the few things you can truly trust.
Opperdienaar
Newbie
*
Offline Offline

Activity: 2
Merit: 0


View Profile
August 02, 2014, 03:48:30 PM
Last edit: August 02, 2014, 04:50:05 PM by Opperdienaar
 #4

I generated some vanity addresses with vanitygen 0.22
I tried to import it in bitcoin core by in the debug window, open wallet, importprivkey "key" label
That all seems to work, the first one actually works, but with the second one, I request on this address to get QR code. It shows a different address from the vanity address. This new address is after this operation available under the same label as the vanity address. When I change the label and repeat a request for payment, it shows another address and this is added to the receive addresses.
Seems like a bug.

Figured it out, you need to click on reuse existing address.
griffga
Member
**
Offline Offline

Activity: 76
Merit: 10


View Profile
August 04, 2014, 01:47:31 AM
 #5

Have you tried using the importprivkey command from the bitcoin-core console area?
Rocket Launcher
Newbie
*
Offline Offline

Activity: 14
Merit: 0


View Profile
August 04, 2014, 04:27:26 AM
 #6

i think to invest more btc without open it just create wallet one who never open it again .
alot hacker easy to copy key if your pc . not get infected
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!