From 7e6d267642157840aee5e248688519080ea384df Mon Sep 17 00:00:00 2001 From: Michael Howe Date: Mon, 8 Jan 2018 15:28:49 +0000 Subject: [PATCH] Add check_cert and deal with messed-up changelog --- debian/changelog | 5 ++++- plugins/check_cert | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 1a744b3..3287de5 100644 --- a/debian/changelog +++ b/debian/changelog @@ -4,8 +4,11 @@ nagios-plugins-local (0.17) unstable; urgency=medium - improve various aspects: + list all unmonitored services, not just the first + exit with unknown state if can't connect to monit's web interface + * check_cert + - fix CN-test regex (in stretch, it looks like openssl includes a space + for 'CN = '). - -- Michael Howe Sat, 09 Dec 2017 22:20:59 +0000 + -- Michael Howe Fri, 22 Dec 2017 23:42:09 +0000 nagios-plugins-local (0.16) unstable; urgency=medium diff --git a/plugins/check_cert b/plugins/check_cert index feec88b..824a912 100755 --- a/plugins/check_cert +++ b/plugins/check_cert @@ -224,7 +224,7 @@ sub parse_certificate { $result{'not_before'} = str2time($1); } elsif ($line =~ /^\s+Not After : (.*)$/ ){ $result{'not_after'} = str2time($1); - } elsif ($line =~ /^\s+Subject:.*, CN=(.*)$/ ){ + } elsif ($line =~ /^\s+Subject:.*, CN\s*=\s*(.*)\s*$/ ){ $result{'cn'} = $1; } } -- 2.39.5