mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-01-25 06:03:40 +03:00
gcrypt: prefer the OS RNG
by default, gcrypt defaults to an userspace RNG, this is the wrong thing (tm) to do on linux. Switch to the SYSTEM rng instead. (cherry picked from commit 80f967311ac53ae43b5a26332f32cc6665661338) (cherry picked from commit ca0ed3a78cc2414706a59384d50b9048e1f00357)
This commit is contained in:
parent
427995b49b
commit
97c82a3abb
@ -15,6 +15,8 @@ void initialize_libgcrypt(bool secmem) {
|
||||
* feature should initialize the library manually */
|
||||
if (!secmem)
|
||||
gcry_control(GCRYCTL_DISABLE_SECMEM);
|
||||
|
||||
gcry_control(GCRYCTL_SET_PREFERRED_RNG_TYPE, GCRY_RNG_TYPE_SYSTEM);
|
||||
gcry_control(GCRYCTL_INITIALIZATION_FINISHED, 0);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user