more debug on ssl error; refs #22

master
Marc Wäckerlin 14 years ago
parent 94fe11262a
commit 718280d00a
  1. 17
      swisssurfer/src/browser.hxx
  2. 18
      swisssurfer/src/downloadmanager.hxx

@ -1102,8 +1102,23 @@ class Browser: public QMainWindow, protected Ui::Browser {
statusBar()->showMessage(tr("ssl error")); statusBar()->showMessage(tr("ssl error"));
// QString e; // QString e;
for (QList<QSslError>::const_iterator err(errors.begin()); for (QList<QSslError>::const_iterator err(errors.begin());
err!=errors.end(); ++err) err!=errors.end(); ++err) {
LOG<<"SSL-Error: "<<err->errorString(); LOG<<"SSL-Error: "<<err->errorString();
LOG<<"Certificate Issuer: "
<<"O="<<err->certificate().issuerInfo(QSslCertificate::Organization)
<<"CN="<<err->certificate().issuerInfo(QSslCertificate::CommonName)
<<"L="<<err->certificate().issuerInfo(QSslCertificate::LocalityName)
<<"OU="<<err->certificate().issuerInfo(QSslCertificate::OrganizationalUnitName)
<<"C="<<err->certificate().issuerInfo(QSslCertificate::CountryName)
<<"ST="<<err->certificate().issuerInfo(QSslCertificate::StateOrProvinceName);
LOG<<"Certificate Subject: "
<<"O="<<err->certificate().subjectInfo(QSslCertificate::Organization)
<<"CN="<<err->certificate().subjectInfo(QSslCertificate::CommonName)
<<"L="<<err->certificate().subjectInfo(QSslCertificate::LocalityName)
<<"OU="<<err->certificate().subjectInfo(QSslCertificate::OrganizationalUnitName)
<<"C="<<err->certificate().subjectInfo(QSslCertificate::CountryName)
<<"ST="<<err->certificate().subjectInfo(QSslCertificate::StateOrProvince);
}
// e+=tr("<li>%1</li>", "single ssl error").arg(err->errorString()); // e+=tr("<li>%1</li>", "single ssl error").arg(err->errorString());
// _error[sender()] += tr("<h2>%1</h2><p>URL: %4</p><p>%2</p>" // _error[sender()] += tr("<h2>%1</h2><p>URL: %4</p><p>%2</p>"
// "<h3>SSL Errors</h3>" // "<h3>SSL Errors</h3>"

@ -164,8 +164,24 @@ class DownloadManager: public QObject {
void sslErrors(const QList<QSslError> & errors) { void sslErrors(const QList<QSslError> & errors) {
LOG; LOG;
for (QList<QSslError>::const_iterator err(errors.begin()); for (QList<QSslError>::const_iterator err(errors.begin());
err!=errors.end(); ++err) err!=errors.end(); ++err) {
LOG<<"SSL-Error: "<<err->errorString(); LOG<<"SSL-Error: "<<err->errorString();
LOG<<"Certificate Issuer: "
<<"O="<<err->certificate().issuerInfo(QSslCertificate::Organization)
<<"CN="<<err->certificate().issuerInfo(QSslCertificate::CommonName)
<<"L="<<err->certificate().issuerInfo(QSslCertificate::LocalityName)
<<"OU="<<err->certificate().issuerInfo(QSslCertificate::OrganizationalUnitName)
<<"C="<<err->certificate().issuerInfo(QSslCertificate::CountryName)
<<"ST="<<err->certificate().issuerInfo(QSslCertificate::StateOrProvinceName);
LOG<<"Certificate Subject: "
<<"O="<<err->certificate().subjectInfo(QSslCertificate::Organization)
<<"CN="<<err->certificate().subjectInfo(QSslCertificate::CommonName)
<<"L="<<err->certificate().subjectInfo(QSslCertificate::LocalityName)
<<"OU="<<err->certificate().subjectInfo(QSslCertificate::OrganizationalUnitName)
<<"C="<<err->certificate().subjectInfo(QSslCertificate::CountryName)
<<"ST="<<err->certificate().subjectInfo(QSslCertificate::StateOrProvince);
}
}
} }
void uploadProgress(qint64 bytesSent, qint64 bytesTotal) { void uploadProgress(qint64 bytesSent, qint64 bytesTotal) {
//LOG<<bytesSent<<bytesTotal; //LOG<<bytesSent<<bytesTotal;

Loading…
Cancel
Save