From 0b6423f9c99d9edf8c96fefd0f6c453859395aa1 Mon Sep 17 00:00:00 2001 From: Holger Weiss Date: Mon, 30 Sep 2013 00:03:24 +0200 Subject: Import Nagios Plugins site Import the Nagios Plugins web site, Cronjobs, infrastructure scripts, and configuration files. --- web/attachments/396772-sslutils_proper_date.patch | 27 +++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 web/attachments/396772-sslutils_proper_date.patch (limited to 'web/attachments/396772-sslutils_proper_date.patch') diff --git a/web/attachments/396772-sslutils_proper_date.patch b/web/attachments/396772-sslutils_proper_date.patch new file mode 100644 index 0000000..6e0ebe0 --- /dev/null +++ b/web/attachments/396772-sslutils_proper_date.patch @@ -0,0 +1,27 @@ +--- sslutils.c 2010-12-23 09:23:37.000000000 +1100 ++++ sslutils.c.orig 2009-05-22 07:11:51.000000000 +1000 +@@ -102,8 +102,7 @@ + struct tm stamp; + float time_left; + int days_left; +-// char timestamp[17] = ""; +- char *timestamp; ++ char timestamp[17] = ""; + + certificate=SSL_get_peer_certificate(s); + if(! certificate){ +@@ -150,13 +149,10 @@ + + time_left = difftime(timegm(&stamp), time(NULL)); + days_left = time_left / 86400; +-/* + snprintf + (timestamp, 17, "%02d/%02d/%04d %02d:%02d", + stamp.tm_mon + 1, + stamp.tm_mday, stamp.tm_year + 1900, stamp.tm_hour, stamp.tm_min); +-*/ +- timestamp = asctime(&stamp); + + if (days_left > 0 && days_left <= days_till_exp) { + printf (_("WARNING - Certificate expires in %d day(s) (%s).\n"), days_left, timestamp); + -- cgit v1.2.3-74-g34f1