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
QDtlsPrivateOpenSSL Class Reference

#include <qdtls_openssl_p.h>

+ Inheritance diagram for QDtlsPrivateOpenSSL:
+ Collaboration diagram for QDtlsPrivateOpenSSL:

Public Member Functions

 QDtlsPrivateOpenSSL (QDtls *qObject, QSslSocket::SslMode mode)
 
unsigned pskClientCallback (const char *hint, char *identity, unsigned max_identity_len, unsigned char *psk, unsigned max_psk_len)
 
unsigned pskServerCallback (const char *identity, unsigned char *psk, unsigned max_psk_len)
 
- Public Member Functions inherited from QDtlsBasePrivate
 QDtlsBasePrivate (QSslSocket::SslMode m, const QByteArray &s)
 
void setDtlsError (QDtlsError code, const QString &description) override
 
QDtlsError error () const override
 
QString errorString () const override
 
void clearDtlsError () override
 
void setConfiguration (const QSslConfiguration &configuration) override
 
QSslConfiguration configuration () const override
 
bool setCookieGeneratorParameters (const GenParams &) override
 
GenParams cookieGeneratorParameters () const override
 

Private Member Functions

QSslSocket::SslMode cryptographMode () const override
 
void setPeer (const QHostAddress &addr, quint16 port, const QString &name) override
 
QHostAddress peerAddress () const override
 
quint16 peerPort () const override
 
void setPeerVerificationName (const QString &name) override
 
QString peerVerificationName () const override
 
virtual void setDtlsMtuHint (quint16 mtu) override
 
virtual quint16 dtlsMtuHint () const override
 
virtual QDtls::HandshakeState state () const override
 
virtual bool isConnectionEncrypted () const override
 
bool startHandshake (QUdpSocket *socket, const QByteArray &datagram) override
 
bool continueHandshake (QUdpSocket *socket, const QByteArray &datagram) override
 
bool resumeHandshake (QUdpSocket *socket) override
 
void abortHandshake (QUdpSocket *socket) override
 
bool handleTimeout (QUdpSocket *socket) override
 
void sendShutdownAlert (QUdpSocket *socket) override
 
QList< QSslErrorpeerVerificationErrors () const override
 
void ignoreVerificationErrors (const QList< QSslError > &errorsToIgnore) override
 
QSslCipher dtlsSessionCipher () const override
 
QSsl::SslProtocol dtlsSessionProtocol () const override
 
qint64 writeDatagramEncrypted (QUdpSocket *socket, const QByteArray &datagram) override
 
QByteArray decryptDatagram (QUdpSocket *socket, const QByteArray &tlsdgram) override
 

Additional Inherited Members

- Static Public Member Functions inherited from QDtlsBasePrivate
static bool isDtlsProtocol (QSsl::SslProtocol protocol)
 
- Public Attributes inherited from QDtlsBasePrivate
QHostAddress remoteAddress
 
quint16 remotePort = 0
 
quint16 mtuHint = 0
 
QDtlsError errorCode = QDtlsError::NoError
 
QString errorDescription
 
QSslConfiguration dtlsConfiguration
 
QSslSocket::SslMode mode = QSslSocket::SslClientMode
 
QSslCipher sessionCipher
 
QSsl::SslProtocol sessionProtocol = QSsl::UnknownProtocol
 
QString peerVfyName
 
QByteArray secret
 
QCryptographicHash::Algorithm hashAlgorithm = QCryptographicHash::Sha256
 

Detailed Description

Definition at line 122 of file qdtls_openssl_p.h.

Constructor & Destructor Documentation

◆ QDtlsPrivateOpenSSL()

QDtlsPrivateOpenSSL::QDtlsPrivateOpenSSL ( QDtls * qObject,
QSslSocket::SslMode mode )

Definition at line 826 of file qdtls_openssl.cpp.

References dtlsopenssl::DtlsState::dtlsPrivate, and Q_ASSERT.

Member Function Documentation

◆ abortHandshake()

void QDtlsPrivateOpenSSL::abortHandshake ( QUdpSocket * socket)
overrideprivate

Definition at line 1057 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::clearDtlsError(), QDtls::HandshakeInProgress, QDtls::PeerVerificationFailed, Q_ASSERT, sendShutdownAlert(), and socket.

+ Here is the call graph for this function:

◆ continueHandshake()

◆ cryptographMode()

QSslSocket::SslMode QDtlsPrivateOpenSSL::cryptographMode ( ) const
overrideprivate

Definition at line 834 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::mode.

◆ decryptDatagram()

◆ dtlsMtuHint()

quint16 QDtlsPrivateOpenSSL::dtlsMtuHint ( ) const
overrideprivatevirtual

Definition at line 871 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::mtuHint.

◆ dtlsSessionCipher()

QSslCipher QDtlsPrivateOpenSSL::dtlsSessionCipher ( ) const
overrideprivate

Definition at line 1099 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::sessionCipher.

◆ dtlsSessionProtocol()

QSsl::SslProtocol QDtlsPrivateOpenSSL::dtlsSessionProtocol ( ) const
overrideprivate

Definition at line 1104 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::sessionProtocol.

◆ handleTimeout()

bool QDtlsPrivateOpenSSL::handleTimeout ( QUdpSocket * socket)
overrideprivate

Definition at line 1017 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::clearDtlsError(), QScopedPointer< T, Cleanup >::data(), QSharedPointer< T >::data(), dtlsutil::next_timeoutMs(), Q_ASSERT, socket, dtlsopenssl::DtlsState::tlsConnection, and dtlsopenssl::DtlsState::udpSocket.

+ Here is the call graph for this function:

◆ ignoreVerificationErrors()

void QDtlsPrivateOpenSSL::ignoreVerificationErrors ( const QList< QSslError > & errorsToIgnore)
overrideprivate

Definition at line 1094 of file qdtls_openssl.cpp.

◆ isConnectionEncrypted()

bool QDtlsPrivateOpenSSL::isConnectionEncrypted ( ) const
overrideprivatevirtual

Definition at line 881 of file qdtls_openssl.cpp.

◆ peerAddress()

QHostAddress QDtlsPrivateOpenSSL::peerAddress ( ) const
overrideprivate

Definition at line 846 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::remoteAddress.

◆ peerPort()

quint16 QDtlsPrivateOpenSSL::peerPort ( ) const
overrideprivate

Definition at line 851 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::remotePort.

◆ peerVerificationErrors()

QList< QSslError > QDtlsPrivateOpenSSL::peerVerificationErrors ( ) const
overrideprivate

Definition at line 1089 of file qdtls_openssl.cpp.

◆ peerVerificationName()

QString QDtlsPrivateOpenSSL::peerVerificationName ( ) const
overrideprivate

Definition at line 861 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::peerVfyName.

◆ pskClientCallback()

unsigned QDtlsPrivateOpenSSL::pskClientCallback ( const char * hint,
char * identity,
unsigned max_identity_len,
unsigned char * psk,
unsigned max_psk_len )

◆ pskServerCallback()

unsigned QDtlsPrivateOpenSSL::pskServerCallback ( const char * identity,
unsigned char * psk,
unsigned max_psk_len )

Definition at line 1263 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::dtlsConfiguration, emit, QSslPreSharedKeyAuthenticator::maximumPreSharedKeyLength(), QSslPreSharedKeyAuthenticator::preSharedKey(), QSslConfiguration::preSharedKeyIdentityHint(), qMin(), QTlsBackend::setupServerPskAuth(), and QSslPreSharedKeyAuthenticator::swap().

+ Here is the call graph for this function:

◆ resumeHandshake()

bool QDtlsPrivateOpenSSL::resumeHandshake ( QUdpSocket * socket)
overrideprivate

Definition at line 1038 of file qdtls_openssl.cpp.

References QList< T >::clear(), QDtlsBasePrivate::clearDtlsError(), QDtls::HandshakeComplete, QDtls::PeerVerificationFailed, Q_ASSERT, Q_UNUSED, and socket.

+ Here is the call graph for this function:

◆ sendShutdownAlert()

void QDtlsPrivateOpenSSL::sendShutdownAlert ( QUdpSocket * socket)
overrideprivate

Definition at line 1074 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::clearDtlsError(), QSharedPointer< T >::data(), Q_ASSERT, q_SSL_shutdown(), socket, dtlsopenssl::DtlsState::tlsConnection, and dtlsopenssl::DtlsState::udpSocket.

Referenced by abortHandshake().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setDtlsMtuHint()

void QDtlsPrivateOpenSSL::setDtlsMtuHint ( quint16 mtu)
overrideprivatevirtual

Definition at line 866 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::mtuHint.

◆ setPeer()

void QDtlsPrivateOpenSSL::setPeer ( const QHostAddress & addr,
quint16 port,
const QString & name )
overrideprivate

◆ setPeerVerificationName()

void QDtlsPrivateOpenSSL::setPeerVerificationName ( const QString & name)
overrideprivate

Definition at line 856 of file qdtls_openssl.cpp.

References QDtlsBasePrivate::peerVfyName.

◆ startHandshake()

◆ state()

QDtls::HandshakeState QDtlsPrivateOpenSSL::state ( ) const
overrideprivatevirtual

Definition at line 876 of file qdtls_openssl.cpp.

◆ writeDatagramEncrypted()


The documentation for this class was generated from the following files: