author | Marc Fournier <marc.fournier@camptocamp.com> | |
Wed, 8 Apr 2015 22:14:37 +0000 (00:14 +0200) | ||
committer | Marc Fournier <marc.fournier@camptocamp.com> | |
Wed, 8 Apr 2015 22:14:37 +0000 (00:14 +0200) |
Conflicts:
src/collectd.conf.pod
src/collectd.conf.pod
1 | 2 | |||
---|---|---|---|---|
src/apache.c | patch | | diff1 | | diff2 | | blob | history |
src/collectd.conf.pod | patch | | diff1 | | diff2 | | blob | history |
diff --cc src/apache.c
index 086a39c814541a658f9d539f5c532860867b07ea,3c4354f2ad63c13a58218a48c127c36f63a8bb27..0c6318e30f31fd02b75a6f7ecf19e1dea334ce8b
--- 1/src/apache.c
--- 2/src/apache.c
+++ b/src/apache.c
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.",
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 8ce4a86d43f891b7fec2ea7b762a248ecabace51,b9d83e591c0e55105a3ce91ba39e078ec92c2346..016edf5dd09313db0eee1a8296e9e5f67c485642
+++ b/src/collectd.conf.pod
possibly need this option. What CA certificates come bundled with C<libcurl>
and are checked by default depends on the distribution you use.
-(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
+ =item B<SSLCiphers> I<list of ciphers>
+
++Specifies which ciphers to use in the connection. The list of ciphers
++must specify valid ciphers. See
++L<http://www.openssl.org/docs/apps/ciphers.html> for details.
++
+=item B<Timeout> I<Milliseconds>
+
+The B<Timeout> option sets the overall timeout for HTTP requests to B<URL>, in
+milliseconds. By default, the configured B<Interval> is used to set the
+timeout.
+
=back
=head2 Plugin C<apcups>