Skip to content
Permalink
Browse files

[auth] fix detection of root CAs on Linux (fixes #13640)

(cherry picked from commit 08ec25b and a6a2982)
  • Loading branch information
jef-n committed Nov 16, 2015
1 parent 8da8700 commit 92ce3572c2b0a86557ccdcafafcff4a3c0c94c10
Showing with 6 additions and 2 deletions.
  1. +2 −2 src/core/auth/qgsauthcertutils.h
  2. +4 −0 src/core/auth/qgsauthmanager.cpp
@@ -25,13 +25,13 @@
#include "qgsauthconfig.h"

#if QT_VERSION >= 0x050000
#define SSL_ISSUER_INFO( var, prop ) var.issuerInfo( prop ).first()
#define SSL_ISSUER_INFO( var, prop ) var.issuerInfo( prop ).value(0)
#else
#define SSL_ISSUER_INFO( var, prop ) var.issuerInfo( prop )
#endif

#if QT_VERSION >= 0x050000
#define SSL_SUBJECT_INFO( var, prop ) var.subjectInfo( prop ).first()
#define SSL_SUBJECT_INFO( var, prop ) var.subjectInfo( prop ).value(0)
#else
#define SSL_SUBJECT_INFO( var, prop ) var.subjectInfo( prop )
#endif
@@ -2360,8 +2360,12 @@ bool QgsAuthManager::removeCertAuthority( const QSslCertificate& cert )

const QList<QSslCertificate> QgsAuthManager::getSystemRootCAs()
{
#ifndef Q_OS_MAC
return QSslSocket::systemCaCertificates();
#else
QNetworkRequest req;
return req.sslConfiguration().caCertificates();
#endif
}

const QList<QSslCertificate> QgsAuthManager::getExtraFileCAs()

0 comments on commit 92ce357

Please sign in to comment.
You can’t perform that action at this time.