2022-05-10 10:06:48 +00:00
|
|
|
// Copyright (C) 2021 The Qt Company Ltd.
|
|
|
|
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
|
2021-05-13 05:32:10 +00:00
|
|
|
|
|
|
|
#include <QtNetwork/qtnetworkglobal.h>
|
|
|
|
|
|
|
|
#if QT_CONFIG(ssl)
|
|
|
|
|
|
|
|
#include <QtNetwork/qsslsocket.h>
|
|
|
|
|
|
|
|
#endif // QT_CONFIG(ssl)
|
|
|
|
|
|
|
|
#include <QtCore/qstring.h>
|
|
|
|
#include <QtCore/qglobal.h>
|
|
|
|
|
|
|
|
QT_BEGIN_NAMESPACE
|
|
|
|
|
|
|
|
namespace TlsAux {
|
|
|
|
|
2021-05-28 09:33:57 +00:00
|
|
|
inline bool classImplemented(QSsl::ImplementedClass cl)
|
2021-05-13 05:32:10 +00:00
|
|
|
{
|
2021-05-28 09:33:57 +00:00
|
|
|
#if QT_CONFIG(ssl)
|
|
|
|
return QSslSocket::implementedClasses().contains(cl);
|
|
|
|
#endif
|
|
|
|
return cl == QSsl::ImplementedClass::Certificate; // This is the only thing our 'cert-only' supports.
|
2021-05-13 05:32:10 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
} // namespace TlsAux
|
|
|
|
|
2021-05-28 09:33:57 +00:00
|
|
|
|
2021-05-13 05:32:10 +00:00
|
|
|
|
|
|
|
QT_END_NAMESPACE
|