From 3b0616a46b0b535631327e6533a2142e5fab3e63 Mon Sep 17 00:00:00 2001 From: Clemens Zeidler Date: Mon, 30 May 2011 21:50:13 +0000 Subject: [PATCH] Add more random into the SSL seed. Thanks Axel. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@41844 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/kits/mail/ServerConnection.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/kits/mail/ServerConnection.cpp b/src/kits/mail/ServerConnection.cpp index dabc6c7fa4..fefc317cf4 100644 --- a/src/kits/mail/ServerConnection.cpp +++ b/src/kits/mail/ServerConnection.cpp @@ -53,10 +53,10 @@ public: return; } - RAND_seed(this, sizeof(InitSSL)); - /*--- Because we're an add-on loaded at an unpredictable time, all the - memory addresses and things contained in ourself are esssentially - random. */ + // use combination of more or less random this pointer and system time + int64 seed = (int64)this + system_time(); + RAND_seed(&seed, sizeof(seed)); + fInit = true; return; };