diff options
author | RincewindsHat <12514511+RincewindsHat@users.noreply.github.com> | 2023-09-18 22:59:46 +0200 |
---|---|---|
committer | RincewindsHat <12514511+RincewindsHat@users.noreply.github.com> | 2023-09-18 22:59:46 +0200 |
commit | 0e70e81133c25274fe2dd2309556b41357dd759b (patch) | |
tree | 9a680b36788ee1ad4e7ecc5ccfeb4494db9fdc72 /plugins/check_ldap.c | |
parent | ce355c80cf6054bfa5e1dcf81f9e2183ef963ee1 (diff) | |
parent | 2ddc75e69db5a3dd379c896d8420c9af20ec1cee (diff) | |
download | monitoring-plugins-0e70e81133c25274fe2dd2309556b41357dd759b.tar.gz |
Merge branch 'master' into mysql_detect_mysqldump
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 bc7bd44c..a1bfe1be 100644 --- a/plugins/check_ldap.c +++ b/plugins/check_ldap.c | |||
@@ -222,7 +222,7 @@ main (int argc, char *argv[]) | |||
222 | /* reset the alarm handler */ | 222 | /* reset the alarm handler */ |
223 | alarm (0); | 223 | alarm (0); |
224 | 224 | ||
225 | /* calcutate the elapsed time and compare to thresholds */ | 225 | /* calculate the elapsed time and compare to thresholds */ |
226 | 226 | ||
227 | microsec = deltime (tv); | 227 | microsec = deltime (tv); |
228 | elapsed_time = (double)microsec / 1.0e6; | 228 | elapsed_time = (double)microsec / 1.0e6; |
@@ -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]"); |