From 718280d00a557af4dd6e845418de0cc4d295a8e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20W=C3=A4ckerlin?= Date: Wed, 27 Apr 2011 11:56:29 +0000 Subject: [PATCH] more debug on ssl error; refs #22 --- swisssurfer/src/browser.hxx | 17 ++++++++++++++++- swisssurfer/src/downloadmanager.hxx | 18 +++++++++++++++++- 2 files changed, 33 insertions(+), 2 deletions(-) diff --git a/swisssurfer/src/browser.hxx b/swisssurfer/src/browser.hxx index 57fe480..e32687f 100644 --- a/swisssurfer/src/browser.hxx +++ b/swisssurfer/src/browser.hxx @@ -1102,8 +1102,23 @@ class Browser: public QMainWindow, protected Ui::Browser { statusBar()->showMessage(tr("ssl error")); // QString e; for (QList::const_iterator err(errors.begin()); - err!=errors.end(); ++err) + err!=errors.end(); ++err) { LOG<<"SSL-Error: "<errorString(); + LOG<<"Certificate Issuer: " + <<"O="<certificate().issuerInfo(QSslCertificate::Organization) + <<"CN="<certificate().issuerInfo(QSslCertificate::CommonName) + <<"L="<certificate().issuerInfo(QSslCertificate::LocalityName) + <<"OU="<certificate().issuerInfo(QSslCertificate::OrganizationalUnitName) + <<"C="<certificate().issuerInfo(QSslCertificate::CountryName) + <<"ST="<certificate().issuerInfo(QSslCertificate::StateOrProvinceName); + LOG<<"Certificate Subject: " + <<"O="<certificate().subjectInfo(QSslCertificate::Organization) + <<"CN="<certificate().subjectInfo(QSslCertificate::CommonName) + <<"L="<certificate().subjectInfo(QSslCertificate::LocalityName) + <<"OU="<certificate().subjectInfo(QSslCertificate::OrganizationalUnitName) + <<"C="<certificate().subjectInfo(QSslCertificate::CountryName) + <<"ST="<certificate().subjectInfo(QSslCertificate::StateOrProvince); + } // e+=tr("
  • %1
  • ", "single ssl error").arg(err->errorString()); // _error[sender()] += tr("

    %1

    URL: %4

    %2

    " // "

    SSL Errors

    " diff --git a/swisssurfer/src/downloadmanager.hxx b/swisssurfer/src/downloadmanager.hxx index a8f519c..4786ca6 100644 --- a/swisssurfer/src/downloadmanager.hxx +++ b/swisssurfer/src/downloadmanager.hxx @@ -164,9 +164,25 @@ class DownloadManager: public QObject { void sslErrors(const QList & errors) { LOG; for (QList::const_iterator err(errors.begin()); - err!=errors.end(); ++err) + err!=errors.end(); ++err) { LOG<<"SSL-Error: "<errorString(); + LOG<<"Certificate Issuer: " + <<"O="<certificate().issuerInfo(QSslCertificate::Organization) + <<"CN="<certificate().issuerInfo(QSslCertificate::CommonName) + <<"L="<certificate().issuerInfo(QSslCertificate::LocalityName) + <<"OU="<certificate().issuerInfo(QSslCertificate::OrganizationalUnitName) + <<"C="<certificate().issuerInfo(QSslCertificate::CountryName) + <<"ST="<certificate().issuerInfo(QSslCertificate::StateOrProvinceName); + LOG<<"Certificate Subject: " + <<"O="<certificate().subjectInfo(QSslCertificate::Organization) + <<"CN="<certificate().subjectInfo(QSslCertificate::CommonName) + <<"L="<certificate().subjectInfo(QSslCertificate::LocalityName) + <<"OU="<certificate().subjectInfo(QSslCertificate::OrganizationalUnitName) + <<"C="<certificate().subjectInfo(QSslCertificate::CountryName) + <<"ST="<certificate().subjectInfo(QSslCertificate::StateOrProvince); + } } + } void uploadProgress(qint64 bytesSent, qint64 bytesTotal) { //LOG<(sender())].first = bytesSent;