diff options
Diffstat (limited to 'plugins/check_curl.c')
-rw-r--r-- | plugins/check_curl.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/plugins/check_curl.c b/plugins/check_curl.c index 9b14486f..b5137129 100644 --- a/plugins/check_curl.c +++ b/plugins/check_curl.c | |||
@@ -157,7 +157,9 @@ int ssl_version = CURL_SSLVERSION_DEFAULT; | |||
157 | char *client_cert = NULL; | 157 | char *client_cert = NULL; |
158 | char *client_privkey = NULL; | 158 | char *client_privkey = NULL; |
159 | char *ca_cert = NULL; | 159 | char *ca_cert = NULL; |
160 | #ifdef HAVE_SSL | ||
160 | X509 *cert = NULL; | 161 | X509 *cert = NULL; |
162 | #endif | ||
161 | int no_body = FALSE; | 163 | int no_body = FALSE; |
162 | int maximum_age = -1; | 164 | int maximum_age = -1; |
163 | int address_family = AF_UNSPEC; | 165 | int address_family = AF_UNSPEC; |
@@ -214,6 +216,8 @@ main (int argc, char **argv) | |||
214 | return result; | 216 | return result; |
215 | } | 217 | } |
216 | 218 | ||
219 | #ifdef HAVE_SSL | ||
220 | |||
217 | int verify_callback(int preverify_ok, X509_STORE_CTX *x509_ctx) | 221 | int verify_callback(int preverify_ok, X509_STORE_CTX *x509_ctx) |
218 | { | 222 | { |
219 | /* TODO: we get all certificates of the chain, so which ones | 223 | /* TODO: we get all certificates of the chain, so which ones |
@@ -231,6 +235,8 @@ CURLcode sslctxfun(CURL *curl, SSL_CTX *sslctx, void *parm) | |||
231 | return CURLE_OK; | 235 | return CURLE_OK; |
232 | } | 236 | } |
233 | 237 | ||
238 | #endif /* HAVE_SSL */ | ||
239 | |||
234 | /* Checks if the server 'reply' is one of the expected 'statuscodes' */ | 240 | /* Checks if the server 'reply' is one of the expected 'statuscodes' */ |
235 | static int | 241 | static int |
236 | expected_statuscode (const char *reply, const char *statuscodes) | 242 | expected_statuscode (const char *reply, const char *statuscodes) |