Bitcoin Forum

Bitcoin => Development & Technical Discussion => Topic started by: muad_dib on October 01, 2011, 01:07:04 AM



Title: Generate 1000 addresses
Post by: muad_dib on October 01, 2011, 01:07:04 AM
If you were to have to generate 1000 Bitcoin Addresses which approach would you take?

Can 1000 addresses be stored in one wallet?



I'm trying to implement the Merchant Lazy API


Title: Re: Generate 1000 addresses
Post by: BurtW on October 01, 2011, 01:29:10 AM
You can go to this website and it will generate as many public/private key pairs as you want/need:  bitaddress.org

Just use the bulk address option, set the number of rows to 1000 and it will generate a CSV file with 1000 addresses and their corresponding private keys.  All the private key generation takes place on your computer, not on the server, so with some care your private keys are secure.


Title: Re: Generate 1000 addresses
Post by: payb.tc on October 01, 2011, 01:37:42 AM
You can go to this website and it will generate as many public/private key pairs as you want/need:  bitaddress.org

Just use the bulk address option, set the number of rows to 1000 and it will generate a CSV file with 1000 addresses and their corresponding private keys.  All the private key generation takes place on your computer, not on the server, so with some care your private keys are secure.

cool, haven't seen that site before.

if it's truly only done on your local machine, then you should be able to save that page full of javascript and run it offline, yes?


Title: Re: Generate 1000 addresses
Post by: BurtW on October 01, 2011, 01:41:02 AM
Just go to the page which will load the script.  Disconnect from the network.  Run the script.  Make address pairs to your hearts conntent.  Save all the files in a secure location.  Reconnect to the evil internet.  Of course you must be aware of any key loggers, etc.


Title: Re: Generate 1000 addresses
Post by: mrb on October 01, 2011, 01:41:26 AM
Code:
for i in `seq 1 1000`; do bitcoind getnewaddress; done >addresses.txt


Title: Re: Generate 1000 addresses
Post by: payb.tc on October 01, 2011, 01:45:21 AM
Just go to the page which will load the script.  Disconnect from the network.  Run the script.  Make address pairs to your hearts conntent.  Save all the files in a secure location.  Reconnect to the evil internet.  Of course you must be aware of any key loggers, etc.

well yes you could do that. although i was thinking more of transporting the javascript via USB to some '100% offline' machine.

anyway, awesome site, is it yours?

mrb: in the past (in older versions), i've found that method hanging bitcoind after 1 or 2 hundred. haven't tried with newer versions.


Title: Re: Generate 1000 addresses
Post by: BurtW on October 01, 2011, 01:48:27 AM
No, but the guy did a great job and I sent him a small donation. 


Title: Re: Generate 1000 addresses
Post by: pointbiz on October 01, 2011, 02:12:44 AM
No, but the guy did a great job and I sent him a small donation. 

Thanks  ;D


Title: Re: Generate 1000 addresses
Post by: pointbiz on October 01, 2011, 02:13:55 AM
if it's truly only done on your local machine, then you should be able to save that page full of javascript and run it offline, yes?

Yes, that's the recommended approach. And verify the SHA-1 hash of the file.


Title: Re: Generate 1000 addresses
Post by: Stephen Gornick on October 01, 2011, 04:12:49 AM
Can 1000 addresses be stored in one wallet

I know this probably isn't what you were asking for, but:  https://en.bitcoin.it/wiki/Key_pool


Title: Re: Generate 1000 addresses
Post by: muad_dib on October 01, 2011, 10:30:15 AM
Can 1000 addresses be stored in one wallet

I know this probably isn't what you were asking for, but:  https://en.bitcoin.it/wiki/Key_pool

Thanx, I almost skipped that.


What happens if I generate 1000 addresses and my key pool is of only 100 addresses? Key Pool is automatically increased?


They should make a command to automatically generate multiple addresses.


Title: Re: Generate 1000 addresses
Post by: Stephen Gornick on October 01, 2011, 07:20:11 PM
What happens if I generate 1000 addresses and my key pool is of only 100 addresses? Key Pool is automatically increased?

Just to make sure you are understanding how the client works:
 - When you click "New" the client is grabbing an address from the key pool and, if necessary, subsequently generating a new address (that you don't yet see) to bring the keypool back to its target size.  So yes, the KeyPool is replenished each time you click New.

So the wallet holds all addresses including the "used" ones given to you when you clicked "new" and also all the "unused" ones from the key pool.  And just to clarify ... I'm referring to an address as "used" not necessarily to mean that it has been used in a transaction but instead just that it is no longer an "unused" address in the key pool.  


Title: Re: Generate 1000 addresses
Post by: muad_dib on October 07, 2011, 08:40:14 PM
What happens if I generate 1000 addresses and my key pool is of only 100 addresses? Key Pool is automatically increased?

Just to make sure you are understanding how the client works:
 - When you click "New" the client is grabbing an address from the key pool and, if necessary, subsequently generating a new address (that you don't yet see) to bring the keypool back to its target size.  So yes, the KeyPool is replenished each time you click New.

So the wallet holds all addresses including the "used" ones given to you when you clicked "new" and also all the "unused" ones from the key pool.  And just to clarify ... I'm referring to an address as "used" not necessarily to mean that it has been used in a transaction but instead just that it is no longer an "unused" address in the key pool.  

Ok so the wallet holds all the old address + 100 (key pool).


Right?>


Title: Re: Generate 1000 addresses
Post by: Stephen Gornick on October 11, 2011, 08:32:27 AM
Ok so the wallet holds all the old address + 100 (key pool).


Right?>

Using the defaults, correct.  The size of the keypool can be specified with a command line argument.