From: Marc Fournier Date: Wed, 8 Apr 2015 22:14:37 +0000 (+0200) Subject: Merge remote-tracking branch 'origin/pr/946' X-Git-Tag: collectd-5.5.0~54 X-Git-Url: https://git.octo.it/?p=collectd.git;a=commitdiff_plain;h=de64a9127f1a6da9052f5d4d55eeadce9d574c85 Merge remote-tracking branch 'origin/pr/946' Conflicts: src/collectd.conf.pod --- de64a9127f1a6da9052f5d4d55eeadce9d574c85 diff --cc src/apache.c index 086a39c8,3c4354f2..0c6318e3 --- a/src/apache.c +++ b/src/apache.c @@@ -208,10 -207,10 +210,12 @@@ static int config_add (oconfig_item_t * status = cf_util_get_boolean (child, &st->verify_host); else if (strcasecmp ("CACert", child->key) == 0) status = cf_util_get_string (child, &st->cacert); + else if (strcasecmp ("SSLCiphers", child->key) == 0) + status = cf_util_get_string (child, &st->ssl_ciphers); else if (strcasecmp ("Server", child->key) == 0) status = cf_util_get_string (child, &st->server); + else if (strcasecmp ("Timeout", child->key) == 0) + status = cf_util_get_int (child, &st->timeout); else { WARNING ("apache plugin: Option `%s' not allowed here.", @@@ -371,15 -365,9 +375,17 @@@ static int init_host (apache_t *st) /* st->verify_host ? 2L : 0L); if (st->cacert != NULL) curl_easy_setopt (st->curl, CURLOPT_CAINFO, st->cacert); + if (st->ssl_ciphers != NULL) + curl_easy_setopt (st->curl, CURLOPT_SSL_CIPHER_LIST,st->ssl_ciphers); +#ifdef HAVE_CURLOPT_TIMEOUT_MS + if (st->timeout >= 0) + curl_easy_setopt (st->curl, CURLOPT_TIMEOUT_MS, (long) st->timeout); + else + curl_easy_setopt (st->curl, CURLOPT_TIMEOUT_MS, + CDTIME_T_TO_MS(plugin_get_interval())); +#endif + return (0); } /* }}} int init_host */ diff --cc src/collectd.conf.pod index 8ce4a86d,b9d83e59..016edf5d --- a/src/collectd.conf.pod +++ b/src/collectd.conf.pod @@@ -775,12 -766,11 +775,18 @@@ File that holds one or more SSL certifi possibly need this option. What CA certificates come bundled with C and are checked by default depends on the distribution you use. + =item B I + -(SSL) Specifies which ciphers to use in the connection. The list of ciphers must -specify valid ciphers. Read up on SSL cipher list details on this URL: - http://www.openssl.org/docs/apps/ciphers.html ++Specifies which ciphers to use in the connection. The list of ciphers ++must specify valid ciphers. See ++L for details. ++ +=item B I + +The B option sets the overall timeout for HTTP requests to B, in +milliseconds. By default, the configured B is used to set the +timeout. + =back =head2 Plugin C