Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qsslpresharedkeyauthenticator.cpp
Go to the documentation of this file.
1// Copyright (C) 2014 Governikus GmbH & Co. KG.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
6
7#include <QSharedData>
8
10
12QT_IMPL_METATYPE_EXTERN_TAGGED(QSslPreSharedKeyAuthenticator*, QSslPreSharedKeyAuthenticator_ptr)
13
14
18 : maximumIdentityLength(0),
19 maximumPreSharedKeyLength(0)
20{
21}
22
80
87
97
103{
104 d = authenticator.d;
105 return *this;
106}
107
130
144
154
155
169
170
184
194
208
232bool QSslPreSharedKeyAuthenticator::isEqual(const QSslPreSharedKeyAuthenticator &other) const
233{
234 return ((d == other.d) ||
235 (d->identityHint == other.d->identityHint &&
236 d->identity == other.d->identity &&
237 d->maximumIdentityLength == other.d->maximumIdentityLength &&
238 d->preSharedKey == other.d->preSharedKey &&
239 d->maximumPreSharedKeyLength == other.d->maximumPreSharedKeyLength));
240}
241
\inmodule QtCore
Definition qbytearray.h:57
The QSslPreSharedKeyAuthenticator class provides authentication data for pre shared keys (PSK) cipher...
Q_NETWORK_EXPORT void setIdentity(const QByteArray &identity)
Sets the PSK client identity (to be advised to the server) to identity.
Q_NETWORK_EXPORT QByteArray identityHint() const
Returns the PSK identity hint as provided by the server.
Q_NETWORK_EXPORT QSslPreSharedKeyAuthenticator()
Constructs a default QSslPreSharedKeyAuthenticator object.
Q_NETWORK_EXPORT QByteArray preSharedKey() const
Returns the pre shared key.
Q_NETWORK_EXPORT int maximumIdentityLength() const
Returns the maximum length, in bytes, of the PSK client identity.
Q_NETWORK_EXPORT ~QSslPreSharedKeyAuthenticator()
Destroys the QSslPreSharedKeyAuthenticator object.
Q_NETWORK_EXPORT QSslPreSharedKeyAuthenticator & operator=(const QSslPreSharedKeyAuthenticator &authenticator)
Assigns the QSslPreSharedKeyAuthenticator object authenticator to this object, and returns a referenc...
Q_NETWORK_EXPORT QByteArray identity() const
Returns the PSK client identity.
Q_NETWORK_EXPORT void setPreSharedKey(const QByteArray &preSharedKey)
Sets the pre shared key to preSharedKey.
Q_NETWORK_EXPORT int maximumPreSharedKeyLength() const
Returns the maximum length, in bytes, of the pre shared key.
Combined button and popup list for selecting options.
#define QT_IMPL_METATYPE_EXTERN_TAGGED(TYPE, TAG)
Definition qmetatype.h:1384
#define QT_IMPL_METATYPE_EXTERN(TYPE)
Definition qmetatype.h:1390
QSharedPointer< T > other(t)
[5]