From e44a0cb9445f79e221efcdb4fbef19353a8801f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20Mr=C3=A1zek?= Date: Wed, 1 Nov 2017 22:52:11 +0100 Subject: NOISSUE catch and log SSL errors for Download(s) --- api/logic/net/Download.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'api/logic/net/Download.cpp') diff --git a/api/logic/net/Download.cpp b/api/logic/net/Download.cpp index 12c1b201..aca0c7d7 100644 --- a/api/logic/net/Download.cpp +++ b/api/logic/net/Download.cpp @@ -135,6 +135,18 @@ void Download::downloadError(QNetworkReply::NetworkError error) } } +void Download::sslErrors(const QList & errors) +{ + int i = 1; + for (auto error : errors) + { + qCritical() << "Download" << m_url.toString() << "SSL Error #" << i << " : " << error.errorString(); + auto cert = error.certificate(); + qCritical() << "Certificate in question:\n" << cert.toText(); + i++; + } +} + bool Download::handleRedirect() { QVariant redirect = m_reply->header(QNetworkRequest::LocationHeader); -- cgit v1.2.3