tst_qsslcertificate - suppress a deprecation warning
In Qt 5 we have to work with the esisting API (QSslCertificate::verify), taking only the peer's chain and the name. We already have a private API to have a CA's list as an additional parameter, the proper fix in Qt6 will also introduce a public complement for this. Pick-to: 5.15 Change-Id: Ib1f75c3056b135c6e6d42f977b5a7034fca658ee Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
This commit is contained in:
parent
a114b133f5
commit
56187f1e45
@ -1000,7 +1000,11 @@ void tst_QSslCertificate::verify()
|
||||
|
||||
// Verify a valid cert signed by a CA
|
||||
QList<QSslCertificate> caCerts = QSslCertificate::fromPath(testDataDir + "verify-certs/cacert.pem", QSsl::Pem, QSslCertificate::PatternSyntax::FixedString);
|
||||
|
||||
QT_WARNING_PUSH
|
||||
QT_WARNING_DISABLE_DEPRECATED
|
||||
QSslSocket::addDefaultCaCertificate(caCerts.first());
|
||||
QT_WARNING_POP
|
||||
|
||||
toVerify = QSslCertificate::fromPath(testDataDir + "verify-certs/test-ocsp-good-cert.pem", QSsl::Pem, QSslCertificate::PatternSyntax::FixedString);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user