From 75b38d1a2ffe57d0f1eb3ebb8c5f30b8b2a185e4 Mon Sep 17 00:00:00 2001 From: Klaas Freitag Date: Tue, 2 Jun 2015 12:21:49 +0200 Subject: [PATCH] Abort the request and reset the QNAM if user does not ACK a new cert. This is supposed to fix bug #3283 --- src/libsync/account.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/libsync/account.cpp b/src/libsync/account.cpp index 8723a8bac..d3e0c76a6 100644 --- a/src/libsync/account.cpp +++ b/src/libsync/account.cpp @@ -503,6 +503,11 @@ void Account::slotHandleErrors(QNetworkReply *reply , QList errors) reply->ignoreSslErrors(); } else { _treatSslErrorsAsFailure = true; + // if during normal operation, a new certificate was MITM'ed, and the user does not + // ACK it, the running request must be aborted and the QNAM must be reset, to not + // treat the new cert as granted. See bug #3283 + reply->abort(); + resetNetworkAccessManager(); return; } }