Outra solução alternativa, ao invés de modificar as fontes do makepasswd, é instalar o daemon haveged para acelerar o processo de geração de chaves. Para instalá-lo:
sudo apt-get install haveged
Depois de instalá-lo, makepasswd funciona como deveria.
O daemon haveged agora é necessário em VMs e iOTs (por exemplo, framboesa), em que a entropia é normalmente baixa.
Do Debian, man haveged :
NAME
haveged- Generate random numbers and feed Linux's random device.DESCRIPTION
havegedgenerates an unpredictable stream of random numbers harvested from the indirect effects of hardware events on hidden processor state (caches, branch predictors, memory translation tables, etc) using the HAVEGE (HArdware Volatile Entropy Gathering and Expansion) algorithm. The algorithm operates in user space, no special privilege is required for file system access to the output stream.Linux pools randomness for distribution by the
/dev/randomand/dev/urandomdevice interfaces. The standard mechanisms of filling the/dev/randompool may not be sufficient to meet demand on systems with high needs or limited user interaction. In those circumstances,havegedmay be run as a privileged daemon to fill the/dev/randompool whenever the supply of random bits in/dev/randomfalls below the low water mark of the device.