aboutsummaryrefslogtreecommitdiff
path: root/src/trinityrealm/Main.cpp
diff options
context:
space:
mode:
authormegamage <none@none>2009-06-02 17:40:22 -0500
committermegamage <none@none>2009-06-02 17:40:22 -0500
commitaa7a91ce90be522adb257200654762678ad5e0b0 (patch)
treeb914645b5acff722630a385f69d96cd0eb6fef58 /src/trinityrealm/Main.cpp
parent47a147721394c696a7eaec75511c891e4e03d402 (diff)
[7937] Check OpenSSL lib at server start up. Author: AlexDereka
--HG-- branch : trunk
Diffstat (limited to 'src/trinityrealm/Main.cpp')
-rw-r--r--src/trinityrealm/Main.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/trinityrealm/Main.cpp b/src/trinityrealm/Main.cpp
index cbadd4d1e4c..7d36f4c9a59 100644
--- a/src/trinityrealm/Main.cpp
+++ b/src/trinityrealm/Main.cpp
@@ -32,6 +32,8 @@
#include "AuthSocket.h"
#include "SystemConfig.h"
#include "Util.h"
+#include <openssl/opensslv.h>
+#include <openssl/crypto.h>
// Format is YYYYMMDDRR where RR is the change in the conf file
// for that day.
@@ -162,6 +164,14 @@ extern int main(int argc, char **argv)
while (pause > clock()) {}
}
+ sLog.outString("%s (Library: %s)", OPENSSL_VERSION_TEXT, SSLeay_version(SSLEAY_VERSION));
+ if (SSLeay() < 0x009080bfL )
+ {
+ sLog.outError("Outdated version of OpenSSL lib, Logins to server impossible!");
+ sLog.outError("minimal required version [OpenSSL 0.9.8k]");
+ return 1;
+ }
+
sLog.outString( "%s (realm-daemon)", _FULLVERSION );
sLog.outString( "<Ctrl-C> to stop.\n" );