diff options
author | Ton Voon <tonvoon@users.sourceforge.net> | 2006-03-24 16:25:46 +0000 |
---|---|---|
committer | Ton Voon <tonvoon@users.sourceforge.net> | 2006-03-24 16:25:46 +0000 |
commit | 293fc70756f2cbc8ad8c7c91e094a83c23d4c059 (patch) | |
tree | 0389484cce40dd9388ff28995acd95a4b29c07c2 | |
parent | f6bfe34a3e3c8c46c2cb5fc728773c2f4b191c8f (diff) | |
download | monitoring-plugins-293fc70756f2cbc8ad8c7c91e094a83c23d4c059.tar.gz |
-C now implies -S/--ssl as well
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1355 f882894a-f735-0410-b71e-b25c423dba1c
-rw-r--r-- | plugins/check_http.c | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/plugins/check_http.c b/plugins/check_http.c index 54e5ff29..58cf83cf 100644 --- a/plugins/check_http.c +++ b/plugins/check_http.c | |||
@@ -253,25 +253,23 @@ process_arguments (int argc, char **argv) | |||
253 | case 'n': /* do not show html link */ | 253 | case 'n': /* do not show html link */ |
254 | display_html = FALSE; | 254 | display_html = FALSE; |
255 | break; | 255 | break; |
256 | case 'S': /* use SSL */ | ||
257 | #ifndef HAVE_SSL | ||
258 | usage4 (_("Invalid option - SSL is not available")); | ||
259 | #endif | ||
260 | use_ssl = TRUE; | ||
261 | if (specify_port == FALSE) | ||
262 | server_port = HTTPS_PORT; | ||
263 | break; | ||
264 | case 'C': /* Check SSL cert validity */ | 256 | case 'C': /* Check SSL cert validity */ |
265 | #ifdef USE_OPENSSL | 257 | #ifdef HAVE_SSL |
266 | if (!is_intnonneg (optarg)) | 258 | if (!is_intnonneg (optarg)) |
267 | usage2 (_("Invalid certificate expiration period"), optarg); | 259 | usage2 (_("Invalid certificate expiration period"), optarg); |
268 | else { | 260 | else { |
269 | days_till_exp = atoi (optarg); | 261 | days_till_exp = atoi (optarg); |
270 | check_cert = TRUE; | 262 | check_cert = TRUE; |
271 | } | 263 | } |
272 | #else | 264 | /* Fall through to -S option */ |
265 | #endif | ||
266 | case 'S': /* use SSL */ | ||
267 | #ifndef HAVE_SSL | ||
273 | usage4 (_("Invalid option - SSL is not available")); | 268 | usage4 (_("Invalid option - SSL is not available")); |
274 | #endif | 269 | #endif |
270 | use_ssl = TRUE; | ||
271 | if (specify_port == FALSE) | ||
272 | server_port = HTTPS_PORT; | ||
275 | break; | 273 | break; |
276 | case 'f': /* onredirect */ | 274 | case 'f': /* onredirect */ |
277 | if (!strcmp (optarg, "follow")) | 275 | if (!strcmp (optarg, "follow")) |