diff options
author | RincewindsHat <12514511+RincewindsHat@users.noreply.github.com> | 2021-12-02 16:42:05 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-12-02 16:42:05 +0100 |
commit | 911e44045d7291f5ede22739fd176ef55dd3de4a (patch) | |
tree | cf36b95a4a964b03d6ecf75770ced2cb3a2ac3a9 /plugins/check_ldap.c | |
parent | 8294af907bd8482a86df749f562b7ec09e3faeed (diff) | |
parent | ed7cdf82a42f16532801ea4f118870ce9a130fcf (diff) | |
download | monitoring-plugins-911e44045d7291f5ede22739fd176ef55dd3de4a.tar.gz |
Merge branch 'master' into fix/shellcheck
Diffstat (limited to 'plugins/check_ldap.c')
-rw-r--r-- | plugins/check_ldap.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/plugins/check_ldap.c b/plugins/check_ldap.c index 66be4b46..845a4f52 100644 --- a/plugins/check_ldap.c +++ b/plugins/check_ldap.c | |||
@@ -237,7 +237,7 @@ main (int argc, char *argv[]) | |||
237 | if(entries_thresholds != NULL) { | 237 | if(entries_thresholds != NULL) { |
238 | if (verbose) { | 238 | if (verbose) { |
239 | printf ("entries found: %d\n", num_entries); | 239 | printf ("entries found: %d\n", num_entries); |
240 | print_thresholds("entry threasholds", entries_thresholds); | 240 | print_thresholds("entry thresholds", entries_thresholds); |
241 | } | 241 | } |
242 | status_entries = get_status(num_entries, entries_thresholds); | 242 | status_entries = get_status(num_entries, entries_thresholds); |
243 | if (status_entries == STATE_CRITICAL) { | 243 | if (status_entries == STATE_CRITICAL) { |
@@ -432,6 +432,9 @@ validate_arguments () | |||
432 | set_thresholds(&entries_thresholds, | 432 | set_thresholds(&entries_thresholds, |
433 | warn_entries, crit_entries); | 433 | warn_entries, crit_entries); |
434 | } | 434 | } |
435 | if (ld_passwd==NULL) | ||
436 | ld_passwd = getenv("LDAP_PASSWORD"); | ||
437 | |||
435 | return OK; | 438 | return OK; |
436 | } | 439 | } |
437 | 440 | ||
@@ -465,7 +468,7 @@ print_help (void) | |||
465 | printf (" %s\n", "-D [--bind]"); | 468 | printf (" %s\n", "-D [--bind]"); |
466 | printf (" %s\n", _("ldap bind DN (if required)")); | 469 | printf (" %s\n", _("ldap bind DN (if required)")); |
467 | printf (" %s\n", "-P [--pass]"); | 470 | printf (" %s\n", "-P [--pass]"); |
468 | printf (" %s\n", _("ldap password (if required)")); | 471 | printf (" %s\n", _("ldap password (if required, or set the password through environment variable 'LDAP_PASSWORD')")); |
469 | printf (" %s\n", "-T [--starttls]"); | 472 | printf (" %s\n", "-T [--starttls]"); |
470 | printf (" %s\n", _("use starttls mechanism introduced in protocol version 3")); | 473 | printf (" %s\n", _("use starttls mechanism introduced in protocol version 3")); |
471 | printf (" %s\n", "-S [--ssl]"); | 474 | printf (" %s\n", "-S [--ssl]"); |