Sometimes generation process of secure key can be a little bit problematic because of not enough random bytes available in software pseudo-random device. You could see a message like this (for PGP key gen):
**We need to generate a lot of random bytes. It is a good idea to perform some other action (type on the keyboard, move the mouse, utilize the disks) during the prime generation; this gives the random number generator a better chance to gain enough entropy. Not enough random bytes available. Please do some other work to give the OS a chance to collect more entropy! (Need 210 more bytes)**
In that case you can use external entropy source for Linux system. On Linux Debian you can use rng-tools package.
# apt-get install rng-tools
rngd can be used with hardware random numers generators, but it can be also used to feed system kernel entropy pool without any hardware. Use the following command to start rngd:
# rngd -r /dev/urandom -o /dev/random
In this example rngd reads lower quality random bytes (but in larger amount) from device /dev/urandom processes it, and writes to /dev/random device.