diff options
Diffstat (limited to 'plugins/check_ldap.c')
-rw-r--r-- | plugins/check_ldap.c | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/plugins/check_ldap.c b/plugins/check_ldap.c index 868ffc1..87818da 100644 --- a/plugins/check_ldap.c +++ b/plugins/check_ldap.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * Monitoring check_ldap plugin | 3 | * Monitoring check_ldap plugin |
4 | * | 4 | * |
5 | * License: GPL | 5 | * License: GPL |
6 | * Copyright (c) 2000-2008 Monitoring Plugins Development Team | 6 | * Copyright (c) 2000-2024 Monitoring Plugins Development Team |
7 | * | 7 | * |
8 | * Description: | 8 | * Description: |
9 | * | 9 | * |
@@ -28,7 +28,7 @@ | |||
28 | 28 | ||
29 | /* progname may be check_ldaps */ | 29 | /* progname may be check_ldaps */ |
30 | char *progname = "check_ldap"; | 30 | char *progname = "check_ldap"; |
31 | const char *copyright = "2000-2008"; | 31 | const char *copyright = "2000-2024"; |
32 | const char *email = "devel@monitoring-plugins.org"; | 32 | const char *email = "devel@monitoring-plugins.org"; |
33 | 33 | ||
34 | #include "common.h" | 34 | #include "common.h" |
@@ -47,37 +47,37 @@ enum { | |||
47 | DEFAULT_PORT = 389 | 47 | DEFAULT_PORT = 389 |
48 | }; | 48 | }; |
49 | 49 | ||
50 | int process_arguments (int, char **); | 50 | static int process_arguments (int, char **); |
51 | int validate_arguments (void); | 51 | static int validate_arguments (void); |
52 | void print_help (void); | 52 | static void print_help (void); |
53 | void print_usage (void); | 53 | void print_usage (void); |
54 | 54 | ||
55 | char ld_defattr[] = "(objectclass=*)"; | 55 | static char ld_defattr[] = "(objectclass=*)"; |
56 | char *ld_attr = ld_defattr; | 56 | static char *ld_attr = ld_defattr; |
57 | char *ld_host = NULL; | 57 | static char *ld_host = NULL; |
58 | char *ld_base = NULL; | 58 | static char *ld_base = NULL; |
59 | char *ld_passwd = NULL; | 59 | static char *ld_passwd = NULL; |
60 | char *ld_binddn = NULL; | 60 | static char *ld_binddn = NULL; |
61 | int ld_port = -1; | 61 | static int ld_port = -1; |
62 | #ifdef HAVE_LDAP_SET_OPTION | 62 | #ifdef HAVE_LDAP_SET_OPTION |
63 | int ld_protocol = DEFAULT_PROTOCOL; | 63 | static int ld_protocol = DEFAULT_PROTOCOL; |
64 | #endif | 64 | #endif |
65 | #ifndef LDAP_OPT_SUCCESS | 65 | #ifndef LDAP_OPT_SUCCESS |
66 | # define LDAP_OPT_SUCCESS LDAP_SUCCESS | 66 | # define LDAP_OPT_SUCCESS LDAP_SUCCESS |
67 | #endif | 67 | #endif |
68 | double warn_time = UNDEFINED; | 68 | static double warn_time = UNDEFINED; |
69 | double crit_time = UNDEFINED; | 69 | static double crit_time = UNDEFINED; |
70 | thresholds *entries_thresholds = NULL; | 70 | static thresholds *entries_thresholds = NULL; |
71 | struct timeval tv; | 71 | static struct timeval tv; |
72 | char* warn_entries = NULL; | 72 | static char* warn_entries = NULL; |
73 | char* crit_entries = NULL; | 73 | static char* crit_entries = NULL; |
74 | bool starttls = false; | 74 | static bool starttls = false; |
75 | bool ssl_on_connect = false; | 75 | static bool ssl_on_connect = false; |
76 | bool verbose = false; | 76 | static bool verbose = false; |
77 | 77 | ||
78 | /* for ldap tls */ | 78 | /* for ldap tls */ |
79 | 79 | ||
80 | char *SERVICE = "LDAP"; | 80 | static char *SERVICE = "LDAP"; |
81 | 81 | ||
82 | int | 82 | int |
83 | main (int argc, char *argv[]) | 83 | main (int argc, char *argv[]) |