[Commits] [SCM] claws branch, master, updated. 3.11.1-141-ge7d7deb

ticho at claws-mail.org ticho at claws-mail.org
Thu Jun 18 23:53:26 CEST 2015


The branch, master has been updated
       via  e7d7deb012e1d5550d2586bb34962ebd4d580055 (commit)
       via  42f80d30efb16beb97ce1b3bd6625653e23e581d (commit)
      from  ab24ae5d5022c744620046c1ab25c898d45ef507 (commit)

Summary of changes:
 src/plugins/rssyl/libfeed/feed.c      |    5 +++--
 src/plugins/rssyl/rssyl_update_feed.c |   12 ++++++++++++
 2 files changed, 15 insertions(+), 2 deletions(-)


- Log -----------------------------------------------------------------
commit e7d7deb012e1d5550d2586bb34962ebd4d580055
Author: Andrej Kacian <ticho at claws-mail.org>
Date:   Thu Jun 18 23:39:12 2015 +0200

    RSSyl: Use our CA certificate bundle on Windows.
    
    Libcurl seems to want a CA cert bundle for any https connection,
    even if verification is disabled. On Windows, there is no default
    bundle or directory libcurl knows about, so we give it our own,
    pointed to by claws_ssl_get_cert_file().

diff --git a/src/plugins/rssyl/rssyl_update_feed.c b/src/plugins/rssyl/rssyl_update_feed.c
index 51d6c97..0f33616 100644
--- a/src/plugins/rssyl/rssyl_update_feed.c
+++ b/src/plugins/rssyl/rssyl_update_feed.c
@@ -169,6 +169,12 @@ RFetchCtx *rssyl_prep_fetchctx_from_item(RFolderItem *ritem)
 	feed_set_cookies_path(ctx->feed, rssyl_prefs_get()->cookies_path);
 	feed_set_ssl_verify_peer(ctx->feed, ritem->ssl_verify_peer);
 	feed_set_auth(ctx->feed, ritem->auth);
+#ifdef G_OS_WIN32
+	if (!g_ascii_strncasecmp(ritem->url, "https", 5)) {
+		feed_set_cacert_file(ctx->feed, claws_ssl_get_cert_file());
+		debug_print("RSSyl: using cert file '%s'\n", feed_get_cacert_file(ctx->feed));
+	}
+#endif
 
 	return ctx;
 }
@@ -188,6 +194,12 @@ RFetchCtx *rssyl_prep_fetchctx_from_url(gchar *url)
 	feed_set_timeout(ctx->feed, prefs_common.io_timeout_secs);
 	feed_set_cookies_path(ctx->feed, rssyl_prefs_get()->cookies_path);
 	feed_set_ssl_verify_peer(ctx->feed, rssyl_prefs_get()->ssl_verify_peer);
+#ifdef G_OS_WIN32
+	if (!g_ascii_strncasecmp(ritem->url, "https", 5)) {
+		feed_set_cacert_file(ctx->feed, claws_ssl_get_cert_file());
+		debug_print("RSSyl: using cert file '%s'\n", feed_get_cacert_file(ctx->feed));
+	}
+#endif
 
 	return ctx;
 }

commit 42f80d30efb16beb97ce1b3bd6625653e23e581d
Author: Andrej Kacian <ticho at claws-mail.org>
Date:   Thu Jun 18 23:37:55 2015 +0200

    RSSyl: If given, set CURLOPT_CAINFO regardless of libcurl version.

diff --git a/src/plugins/rssyl/libfeed/feed.c b/src/plugins/rssyl/libfeed/feed.c
index 1ddeb44..b4db22e 100644
--- a/src/plugins/rssyl/libfeed/feed.c
+++ b/src/plugins/rssyl/libfeed/feed.c
@@ -306,11 +306,12 @@ guint feed_update(Feed *feed, time_t last_update)
 	if (feed->ssl_verify_peer == FALSE) {
 		curl_easy_setopt(eh, CURLOPT_SSL_VERIFYPEER, 0);
 		curl_easy_setopt(eh, CURLOPT_SSL_VERIFYHOST, 0);
-		if (feed->cacert_file != NULL)
-			curl_easy_setopt(eh, CURLOPT_CAINFO, feed->cacert_file);
 	}
 #endif
 
+	if (feed->cacert_file != NULL)
+		curl_easy_setopt(eh, CURLOPT_CAINFO, feed->cacert_file);
+
 	if(feed->cookies_path != NULL)
 		curl_easy_setopt(eh, CURLOPT_COOKIEFILE, feed->cookies_path);
 

-----------------------------------------------------------------------


hooks/post-receive
-- 
Claws Mail


More information about the Commits mailing list