check_dig: expected address is an exact match (#1385)
Oliver Skibbe <[email protected]> Wed, 14 Oct 2015 00:11:12 -0700
| Newsgroups | gmane.network.nagios.devel |
|---|---|
| Message-ID | <monitoring-plugins/monitoring-plugins/issues/[email protected]> |
Expected address is not fully matched for example Assume i have a host which has the IP 173.194.116.215 and i want to check against it: ``´./check_dig -H dns1 -vvvv -l www.google.de -a 173.194.116.215``` As expected check_dig returns OK, but if its checked for .21: ``´./check_dig -H dns1 -vvvv -l www.google.de -a 173.194.116.21``` It returns also OK, because strstr/strcasestr just locate substrings but it might return a WARNING/CRITICAL because it matches not 100% To not break working setups we could add a new option -e --exact-match which toggles strict checking and then returns WARN/CRIT if the result and the expected result do not match 100% --- Reply to this email directly or view it on GitHub: https://github.com/monitoring-plugins/monitoring-plugins/issues/1385