代码拉取完成,页面将自动刷新
From a033fe378d1683354adc3718fbdc7c07f793206d Mon Sep 17 00:00:00 2001
From: Debarshi Ray <debarshir@gnome.org>
Date: Thu, 14 Oct 2021 16:55:48 +0200
Subject: [PATCH] skydrive: Guard against invalid SSL certificates
Fixes: CVE-2021-39360
https://gitlab.gnome.org/GNOME/libzapojit/-/issues/4
---
src/zpj-skydrive.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/zpj-skydrive.c b/src/zpj-skydrive.c
index c91b126..1d91d31 100644
--- a/src/zpj-skydrive.c
+++ b/src/zpj-skydrive.c
@@ -415,6 +415,7 @@ zpj_skydrive_delete_entry_id (ZpjSkydrive *self, const gchar *entry_id, GCancell
goto out;
session = soup_session_sync_new ();
+ g_object_set (session, SOUP_SESSION_SSL_USE_SYSTEM_CA_FILE, TRUE, NULL);
url = g_strconcat (live_endpoint, entry_id, NULL);
message = soup_message_new ("DELETE", url);
@@ -744,6 +745,7 @@ zpj_skydrive_download_file_id_to_path (ZpjSkydrive *self,
data.loop = g_main_loop_new (context, FALSE);
session = soup_session_async_new_with_options (SOUP_SESSION_USE_THREAD_CONTEXT, TRUE, NULL);
+ g_object_set (session, SOUP_SESSION_SSL_USE_SYSTEM_CA_FILE, TRUE, NULL);
url = g_strconcat (live_endpoint, file_id, "/content", NULL);
message = soup_message_new ("GET", url);
@@ -1291,6 +1293,7 @@ zpj_skydrive_upload_path_to_folder_id (ZpjSkydrive *self,
goto out;
session = soup_session_sync_new ();
+ g_object_set (session, SOUP_SESSION_SSL_USE_SYSTEM_CA_FILE, TRUE, NULL);
url = g_strconcat (live_endpoint, folder_id, "/files", NULL);
message = soup_message_new ("POST", url);
--
2.27.0
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。