cURL / Mailing Lists / curl-library / Single Mail


seeding SSL once

From: Daniel Stenberg <>
Date: Wed, 30 Jan 2002 08:55:53 +0100 (MET)

T. Bharath rightfully pointed out to me that the current libcurl seeds the
SSL random stuff before *every* single SSL connection.

As this can be a time-consuming operation and it is a *seeding* I can't
figure out a single good reason why we would ever do this more than once for
an application's entire life-time!

I have therefore committed code that now will make the seeding before the
first connection and then never again. Never in the sense of an application's
life-time. The 'ssl is seeded' variable is a global variable, so it'll
survive the comings and goings of easy handles etc.

Ok, I lied. I can think of one reason why one could possibly want to re-seed,
and that is if the initial seeding was done based on a not-good-enough random
source and another better one pops up for a subsequent operation.

Still, can anyone think of any real-world scenario when this would apply?

    Daniel Stenberg -- curl groks URLs --
Received on 2002-01-30