Hello. There appears to be an issue with the FIPS-approved version of PRNG.
Specifically, fips_rand_bytes(), which is the RAND_bytes() for the FIPS rand
method, checks whether the "key pid" and the "seed pid" (both are static
variables set by FIPS_set_prng_key() and FIPS_rand_seed() respectively)
match current PID. The function fails if the PID does not match. However,
since PID is obtained by calling getpid(2), under Linux it is going to be
different in different threads. Given this, using rand-related functions
concurrently from different threads is not practical: each thread would need
to re-seed and reset the key each time before calling RAND_bytes(), plus the
calls would need to be synchronized.

An apparent solution for this would be to define GETPID_IS_MEANINGLESS under
Linux, but the Security Policy appears to prohibit any configuration options
except "fips".

Does the FIPS module development team have any thoughts on this?

Thank you.

--
Best regards,
Dmitriy Khodos

______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to