Fix windows cert fetcher if site presents full chain
authorShane Kearns <ext-shane.2.kearns@nokia.com>
Fri, 27 Apr 2012 19:05:05 +0000 (20:05 +0100)
committerQt by Nokia <qt-info@nokia.com>
Fri, 4 May 2012 01:10:39 +0000 (03:10 +0200)
commit42d4639fd95b098ff087afa9fc325adf906e2f55
tree58285d6359175d1bd1251226ea42d1be44064296
parentf503e906d6849fc7a2fef57a52b44194030bc5ed
Fix windows cert fetcher if site presents full chain

If a website presents the complete certificate chain in the handshake
i.e. site -> intermediate CA -> root CA then openssl gives
a different error (SelfSignedCertificateInChain)

Because of this windows feature, that either means the site is
signed by an untrusted CA, or the CA trust status is unknown because
we don't have the root cert in the cert store.

In any case, calling the windows verification function results
in a trusted chain & the root being added to the cert store.

Task-number: QTBUG-24827
Change-Id: I2663ea2f86cd0b4dfde105d858ec1b39a340c1f6
Reviewed-by: Richard J. Moore <rich@kde.org>
src/network/ssl/qsslsocket_openssl.cpp