dovecot-2.2: lib-http: Added ssl_ca setting to specify the CA ce...

dovecot at dovecot.org dovecot at dovecot.org
Tue Apr 2 23:32:22 EEST 2013


details:   http://hg.dovecot.org/dovecot-2.2/rev/c256b246302d
changeset: 16139:c256b246302d
user:      Timo Sirainen <tss at iki.fi>
date:      Tue Apr 02 23:29:43 2013 +0300
description:
lib-http: Added ssl_ca setting to specify the CA certificate directly.

diffstat:

 src/lib-http/http-client-peer.c |  1 +
 src/lib-http/http-client.c      |  1 +
 src/lib-http/http-client.h      |  2 +-
 3 files changed, 3 insertions(+), 1 deletions(-)

diffs (34 lines):

diff -r f11ffd0e8b16 -r c256b246302d src/lib-http/http-client-peer.c
--- a/src/lib-http/http-client-peer.c	Tue Apr 02 23:11:30 2013 +0300
+++ b/src/lib-http/http-client-peer.c	Tue Apr 02 23:29:43 2013 +0300
@@ -228,6 +228,7 @@
 		const char *source;
 		memset(&ssl_set, 0, sizeof(ssl_set));
 		ssl_set.ca_dir = peer->client->set.ssl_ca_dir;
+		ssl_set.ca = peer->client->set.ssl_ca;
 		ssl_set.verify_remote_cert = TRUE;
 		ssl_set.crypto_device = peer->client->set.ssl_crypto_device;
 
diff -r f11ffd0e8b16 -r c256b246302d src/lib-http/http-client.c
--- a/src/lib-http/http-client.c	Tue Apr 02 23:11:30 2013 +0300
+++ b/src/lib-http/http-client.c	Tue Apr 02 23:29:43 2013 +0300
@@ -82,6 +82,7 @@
 	if (set->rawlog_dir != NULL && *set->rawlog_dir != '\0')
 		client->set.rawlog_dir = p_strdup(pool, set->rawlog_dir);
 	client->set.ssl_ca_dir = p_strdup(pool, set->ssl_ca_dir);
+	client->set.ssl_ca = p_strdup(pool, set->ssl_ca);
 	client->set.max_idle_time_msecs = set->max_idle_time_msecs;
 	client->set.max_parallel_connections =
 		(set->max_parallel_connections > 0 ? set->max_parallel_connections : 1);
diff -r f11ffd0e8b16 -r c256b246302d src/lib-http/http-client.h
--- a/src/lib-http/http-client.h	Tue Apr 02 23:11:30 2013 +0300
+++ b/src/lib-http/http-client.h	Tue Apr 02 23:29:43 2013 +0300
@@ -33,7 +33,7 @@
 struct http_client_settings {
 	const char *dns_client_socket_path;
 
-	const char *ssl_ca_dir;
+	const char *ssl_ca_dir, *ssl_ca;
 	const char *ssl_crypto_device;
 	bool ssl_allow_invalid_cert;
 	bool ssl_verify;


More information about the dovecot-cvs mailing list