mirror of https://github.com/sipwise/rtpengine.git
random(), and mutilations of the output of the same, are not suitable
for generating cryptographic keys. Use RAND_bytes() from openssl.
We can do this without seeding during daemon initialization because:
- rtpengine in Linux-specific.
- openssl seeds transparently when /dev/urandom is present.
From RAND_seed(3):
On systems that provide "/dev/urandom", the randomness device is used
to seed the PRNG transparently. However, on all other systems, the
application is responsible for seeding the PRNG by calling RAND_add(),
RAND_egd(3) or RAND_load_file(3).
pull/69/head
parent
e24253a709
commit
9a2da87f13
Loading…
Reference in new issue