How to generate a bulk wallet offline with python, java or c++? I want to generate, say 100000 key pairs (address/private key). It should be done offline, without using websites/javascript , with a program on the command line. Of course, the software should use the best way to generate randomness. There is such function on https://www.bitaddress.org , but it's javascript and is not easy to be used by scripts on the command line. Do you know of such software?
A very simple way is to use Vanitygen with the following command:

vanitygen -k -o output.txt -s seeds.txt 1



-k keeps it going after it finds a hit
-o output.txt will write the key pairs to the file output.txt
-s seeds.txt will let you have different seeds. Create this on beforehand
1 is the pattern Vanitygen will look for. Because all addresses start with 1, every hit will be good. Also nice if you want to have nice addresses, like 1Hristo or something. Keep in mind that it will reduce speed ALOT.


Vanitygen creates about 300 kKey/second on my 2010 MBP CPU. With oclvanitygen it is around 750 kKeys/second. The output.txt will reduce the speed a bit, but it will not take a lifetime. I am not on a computer right now on which I can test the command, but it should work. 

This will generate key pairs until infinity. If you really want to have exactly 1000000 (or any other number) pairs, try something with a bash for-loop, and something like 

vanitygen 1 &gt;&gt; output.txt


Again, I cannot check this right now, so I don't know how the pairs will be in the output.txt, but it should be appended and readable for you.