On 4/25/2014 11:19 PM, summer wrote:
Furthur investigation shows the slowness is happening at _ssl.c line 306,
self->ctx = SSL_CTX_new(SSLv23_method()); /* Set up context */
Is this line code involving client/server communication yet?
I haven't checked, but maybe SSL_CTX_new() is initializing the OpenSSL
random number generator, which in turn initializes a shared random state
in the OS (/dev/random on *n*x, CryptoAPI RNG on Windows) or on disk
(".rnd" file).
This takes some time the first time in order to gather lots of random
events from around the system, while later calls (by any app) will cheat
and use what is already there.
Thus the slowness should be happening in whichever OpenSSL-based program
is run first. If the slow init is in the System random state, it should
happen in the first crypto program (OpenSSL-based or not) is run first.
Just a theory, I haven't checked the full call graph of SSL_CTX_new()
and SSLv23_method().
Enjoy
Jakob
--
Jakob Bohm, CIO, Partner, WiseMo A/S. http://www.wisemo.com
Transformervej 29, 2730 Herlev, Denmark. Direct +45 31 13 16 10
This public discussion message is non-binding and may contain errors.
WiseMo - Remote Service Management for PCs, Phones and Embedded
______________________________________________________________________
OpenSSL Project http://www.openssl.org
User Support Mailing List openssl-users@openssl.org
Automated List Manager majord...@openssl.org