summaryrefslogtreecommitdiffstats
path: root/plugins
AgeCommit message (Collapse)AuthorFilesLines
2012-06-27check_tcp: Print performance data even with -DHolger Weiss1-1/+1
When using the 1.4.15 release of the Nagios Plugins, a command such as check_tcp -H pop.example.com -p 995 -D 14 usually produced two lines of output, e.g.: OK - Certificate will expire on 12/13/2014 23:59. TCP OK - 0.009 second response time on port 995|time=0.008849s;;;0.000000;10.000000 The second line was removed by 4d06603060fc1233861b164870f0d3a2e0d8d2eb. However, as the old two-line output is a valid (though in this case unintended) way to spit out performance data, removing the second line might break current setups. Therefore, we revert to the old behaviour, at least for the moment. The issue was reported by Jochen Bern on the "nagiosplug-devel" mailing list (Message-ID: <4FEAE812.8030309@LINworks.de>).
2012-06-26check_snmp: use single quotes for perf data labelsSven Nierlein2-4/+8
2012-06-26Fix performance data label containing spaces in check_snmp (Jochen Bern)Sven Nierlein2-4/+45
Add --perf-oids option for check_snmp to retain optional 1.4.14 compatibility
2012-06-25added test case for certificate checs with both warning and critical valuesWilliam Leibzon1-0/+4
2012-06-25check_http: added test for warning thresholdsSven Nierlein3-3/+11
fixed typo in sslutils
2012-06-25applied patch that adds both critical and warning thresholds to certificate ↵William Leibzon5-33/+89
expiration checks of check_tcp, check_http, check_smtp
2012-06-24check_ping: Add missing newline to die() callsHolger Weiss1-11/+11
Our die() function expects the caller to append the trailing newline character.
2012-06-24Merge remote-tracking branch 'github/waja/master'Holger Weiss1-0/+2
Conflicts: NEWS
2012-06-24check_ping: Ignore ping(1)'s exit statusHolger Weiss1-3/+1
Don't return a WARNING state if the number of lost packets is greater than zero but below the specified warning threshold. This happened because the check_ping plugin used the exit status of the ping(1) utility. (#3535140 - Tobias Brox)
2012-06-22Fix check_by_ssh test for non-Bash login shellsHolger Weiss1-5/+5
In the C shell and in the Z shell, the "?" character must be quoted or backslash-escaped in order to use it verbatim. Therefore, a command such as check_by_ssh -H test.example.com -l joe echo huh? might fail, depending on joe's login shell on test.example.com. Just to make sure, this commit removes most punctuation characters from our test strings.
2012-06-11Improve parsing of ping6(1) outputHolger Weiss1-17/+19
The ping6(1) implementation provided by Debian's iputils-ping package may produce output such as the following: | 3 packets transmitted, 0 received, +3 errors, 100% packet loss, time 2009ms There's a corresponding pattern in check_ping.c:458: | "%*d packets transmitted, %*d received, +%*d errors, %d%% packet loss" Without this fix, the pattern in check_ping.c:456 matched first (as sscanf(3) interprets "+3" as a match for "%d"): | "%*d packets transmitted, %*d received, %d%% loss, time" (#1894850 - Debian bug report #514588 - Matej Vela)
2012-06-11Fix whitespace and capitalization issuesHolger Weiss1-80/+80
Fix indentation and whitespace issues, and correct some capitalization errors in error messages. The behaviour is unchanged.
2012-06-11Don't use SSLv2 when compiling against GnuTLSHolger Weiss1-2/+2
GnuTLS doesn't support SSL version 2.
2012-06-07check_users: Whitespace fixes, etc.Holger Weiss1-24/+14
2012-06-07check_users: improve performanceM. Remy2-31/+9
This patch use the utxent function family to collect the user data. It improve the check speed. Need a system conforming to POSIX.1-2001.
2012-06-06sslutils: Check if OpenSSL supports SSLv2.refs/pull/6/headSebastian Harl1-0/+5
Recent versions/builds seem to disable that feature.
2012-05-29check_http: Fix -C/--certificate option handlingHolger Weiss1-1/+1
The support for specifying the desired SSL protocol version via an optional -S/--ssl argument broke the -C/--certificate option. This is fixed now.
2012-05-28check_http: Don't ignore SSL initialization errorsHolger Weiss1-1/+3
SSL initialization errors are now handled properly by check_http (#3095106 - Eric Schoeller).
2012-05-28Add support for specifying SSL protocol versionHolger Weiss2-8/+40
The check_http -S/--ssl option now takes an optional argument which specifies the desired SSL/TLS protocol version (#3285367 - Jason Lunn).
2012-05-07Disable stateless SSL session resumptionHolger Weiss1-0/+3
Some versions of OpenSSL fail to negotiate the SSL connection with at least some versions of Tomcat if stateless SSL session resumption support (see RFC4507) is enabled: | CRITICAL - Cannot make SSL connection | 140099330348712:error:140943F2:SSL routines:SSL3_READ_BYTES:sslv3 alert unexpected message:s3_pkt.c:1195:SSL alert number 10 The problem is reproducible with OpenSSL 1.0.0h, but not with OpenSSL 0.9.8o-4squeeze12 (as shipped with Debian 6.0.4). We work around it by disabling the RFC4507 functionality when using OpenSSL versions which support it. Thanks to Dag Bakke for reporting the issue and for giving me access to a server I could use to reproduce the problem.
2012-04-17Fix check_ping where output of ping6 when unreachable (Debian #662638)refs/pull/2/headJan Wagner1-0/+2
2012-04-10Merge branch 'master' of ↵Matthias Eble6-14/+42
ssh://nagiosplug.git.sourceforge.net/gitroot/nagiosplug/nagiosplug
2012-04-09check_by_ssh: added -F config file to specify alternative ssh configSven Nierlein2-3/+21
2012-02-24Clarify that check_http won't verify certificatesHolger Weiss1-0/+4
Add a note to the --help output which clarifies that check_http doesn't perform certificate verification (beyond what the "-C" option does). (Suggested by Michael Renner in Debian bug report #644627, forwarded by Jan Wagner.)
2012-02-24Cosmetic changeHolger Weiss1-7/+7
Replace all occurrences of "strstr(s, "c") == s" with "s[0] == 'c'".
2012-02-24Accept multiple labels specified with "-l"Holger Weiss1-3/+3
Fix the code which accepts a comma-separated list of labels specified via the "-l" option. (Spotted by Oskar Liljeblad in Debian bug report #647020, forwarded by Jan Wagner.)
2012-02-10Enable compiling on AIX 6.1Eric Stanley1-0/+6
2011-09-07Make GCC happyThomas Guyot-Sionnest1-1/+1
It won't trust us about msg containing no format string, and fail miserably when compiled with -Werror=format-security. Reported by spy6 on IRC.
2011-08-13Fix: check_ldap now correctly handles the long option --hostname for -HMatthias Eble1-1/+1
The undocumented --host has been changed to --hostname which is actually mentioned in --help. Thanks to lgarrett (#3191388)
2011-07-15Fix check_smtp and check_tcp where duplicate messages were displayed for ↵Ton Voon2-7/+1
certificate errors (Opsview team)
2011-07-15New option to check_smtp to ignore failures when sending QUIT (#3358348 - ↵Ton Voon1-4/+26
Duncan Ferguson)
2011-03-26Add perfdata to check_ssh (#3244097 - Marco Beck)Thomas Guyot-Sionnest1-2/+9
2011-02-08check_smtp: Abort on missing/unexpected greetingHolger Weiss1-2/+2
Abort immediately if we don't receive a server greeting or if the greeting doesn't contain the "--expect"ed string (by default: "220") instead of blindly sending the EHLO/HELO line. Spotted by Daniel Piddock, see Debian bug report #611914.
2011-02-04check_http: check for and print the certificate cnThomas Guyot-Sionnest3-14/+32
This patch adds a check for the certificate cn (hostname) to normal certificate checks. It returns CRITICAL if th cn is missing, otherwise it prints it in the normal output. Patch by Stéphane Urbanovski
2011-01-21Fix for regex input of '|', being output causing problems with Nagios' ↵Ton Voon2-2/+15
parsing of performance data. Now replaced with ','
2011-01-06Test updates...Thomas Guyot-Sionnest3-5/+9
1. Timetick test could fail with uptime > 115 days. Thresholds are double type, so it's safe to put a large number even for 32bit systems. 2. Add a test based on an invalid bug report, worthy anyway.
2011-01-01Make check_http use standard threshold functionsThomas Guyot-Sionnest1-30/+18
This enables floating point and ranges, and make the code more standard.
2010-12-23Fix check_ldap overriding the port when --ssl was specified after -pThomas Guyot-Sionnest1-2/+6
2010-12-01Fix minor test issuesThomas Guyot-Sionnest2-21/+28
My Test::More wouldn't print the total number of tests anymore, moving the plan at the top appears to fix it. At the same time I made check-http.t eval the special modules so it can skip the tests instead of failing.
2010-12-01Revert "check_snmp now considers strings returned by SNMP that contain just"Thomas Guyot-Sionnest2-19/+1
This reverts commit 896962a1ad1b7d7c75d42c565b06cc799feb0a7c. Conflicts: NEWS plugins/tests/check_snmp.t Notes: Reverting because I rebased a patch that was doing the same thing, plus fixing more related regressions, and both didn't work together. I kept the tests intact except for one that wouldn't pass on 1.4.14 either
2010-12-01State-based tests enhancementsThomas Guyot-Sionnest1-1/+4
- Use /var/tmp for state if no state dir environment variable is set, this avoid the need for a writable localstatedir during tests. - Use "rm -f", mostly to avoid printing out garbage of the directory doesn't exists
2010-12-01check_snmp: Remove that is_numeric madnessThomas Guyot-Sionnest2-9/+12
Original patch to make Timeticks works as in check_snmp v1.4.14, it turns out is_numeric isn't so useful and treating all types as numeric works best for backwards-compatibility. This is how it used to work in 1.4.14. As a special case, I also make calculate_rate look up for numeric values as it would otherwise return the last value instead.
2010-11-15Fix check_disk free space calculation if blocksizes differ within a disk ↵Matthias Eble1-81/+94
group (Bekar - #2973603) Various values (dused_pct, dfree_pct, inodes_free, inodes_total, ...) are now carried in the parameter_list structure. Assignments have been moved to a subroutine preventing code redundancies. Group metrics are now calculated based on units rather than blocks. This fixes freespace calculation when blocksizes differ within a group.
2010-11-15check_snmp now considers strings returned by SNMP that contain justnagios3-4/+33
numbers (according to strtod) to be a numeric value for threshold and performance data
2010-10-15check_nt: make UPTIME accept warning/critical levelsThomas Guyot-Sionnest1-1/+6
Patch originally by Ryan Kelly
2010-08-31Fix typos in -f help textTon Voon1-1/+1
2010-07-09Fix --help output when MAX_OIDS is altered.Thomas Guyot-Sionnest1-2/+2
2010-07-07Fix examples in check_disk, where it implied was possible to suffix unit ↵Ton Voon1-2/+2
values to warn/crit parameters
2010-06-30Corrected rate_multiplier calculationtonvoon2-2/+2
2010-06-30Removed suffix of "-rate" and let user decide label via --labeltonvoon2-7/+5