QtBase  v6.3.1
Public Member Functions | Friends | List of all members
QSslCipher Class Reference

The QSslCipher class represents an SSL cryptographic cipher. More...

#include <qsslcipher.h>

Public Member Functions

 QSslCipher ()
 
 QSslCipher (const QString &name)
 
 QSslCipher (const QString &name, QSsl::SslProtocol protocol)
 
 QSslCipher (const QSslCipher &other)
 
QSslCipheroperator= (QSslCipher &&other) noexcept
 
QSslCipheroperator= (const QSslCipher &other)
 
 ~QSslCipher ()
 
void swap (QSslCipher &other) noexcept
 
bool operator== (const QSslCipher &other) const
 
bool operator!= (const QSslCipher &other) const
 
bool isNull () const
 
QString name () const
 
int supportedBits () const
 
int usedBits () const
 
QString keyExchangeMethod () const
 
QString authenticationMethod () const
 
QString encryptionMethod () const
 
QString protocolString () const
 
QSsl::SslProtocol protocol () const
 

Friends

class QTlsBackend
 

Detailed Description

The QSslCipher class represents an SSL cryptographic cipher.

Since
4.3

\reentrant

\inmodule QtNetwork

QSslCipher stores information about one cryptographic cipher. It is most commonly used with QSslSocket, either for configuring which ciphers the socket can use, or for displaying the socket's ciphers to the user.

See also
QSslSocket, QSslKey

Definition at line 57 of file qsslcipher.h.

Constructor & Destructor Documentation

◆ QSslCipher() [1/4]

QSslCipher::QSslCipher ( )

Constructs an empty QSslCipher object.

Definition at line 77 of file qsslcipher.cpp.

◆ QSslCipher() [2/4]

QSslCipher::QSslCipher ( const QString name)
explicit
Since
5.3

Constructs a QSslCipher object for the cipher determined by name. The constructor accepts only supported ciphers (i.e., the name must identify a cipher in the list of ciphers returned by QSslSocket::supportedCiphers()).

You can call isNull() after construction to check if name correctly identified a supported cipher.

Definition at line 93 of file qsslcipher.cpp.

Here is the call graph for this function:

◆ QSslCipher() [3/4]

QSslCipher::QSslCipher ( const QString name,
QSsl::SslProtocol  protocol 
)

Constructs a QSslCipher object for the cipher determined by name and protocol. The constructor accepts only supported ciphers (i.e., the name and protocol must identify a cipher in the list of ciphers returned by QSslSocket::supportedCiphers()).

You can call isNull() after construction to check if name and protocol correctly identified a supported cipher.

Definition at line 115 of file qsslcipher.cpp.

Here is the call graph for this function:

◆ QSslCipher() [4/4]

QSslCipher::QSslCipher ( const QSslCipher other)

Constructs an identical copy of the other cipher.

Definition at line 130 of file qsslcipher.cpp.

Here is the call graph for this function:

◆ ~QSslCipher()

QSslCipher::~QSslCipher ( )

Destroys the QSslCipher object.

Definition at line 139 of file qsslcipher.cpp.

Member Function Documentation

◆ authenticationMethod()

QString QSslCipher::authenticationMethod ( ) const

Returns the cipher's authentication method as a QString.

Definition at line 227 of file qsslcipher.cpp.

◆ encryptionMethod()

QString QSslCipher::encryptionMethod ( ) const

Returns the cipher's encryption method as a QString.

Definition at line 235 of file qsslcipher.cpp.

◆ isNull()

bool QSslCipher::isNull ( ) const

Returns true if this is a null cipher; otherwise returns false.

Definition at line 180 of file qsslcipher.cpp.

Here is the caller graph for this function:

◆ keyExchangeMethod()

QString QSslCipher::keyExchangeMethod ( ) const

Returns the cipher's key exchange method as a QString.

Definition at line 219 of file qsslcipher.cpp.

◆ name()

QString QSslCipher::name ( ) const

Returns the name of the cipher, or an empty QString if this is a null cipher.

See also
isNull()

Definition at line 191 of file qsslcipher.cpp.

Here is the caller graph for this function:

◆ operator!=()

bool QSslCipher::operator!= ( const QSslCipher other) const
inline

Returns true if this cipher is not the same as other; otherwise, false is returned.

Definition at line 72 of file qsslcipher.h.

Here is the call graph for this function:

◆ operator=() [1/2]

QSslCipher & QSslCipher::operator= ( const QSslCipher other)

Copies the contents of other into this cipher, making the two ciphers identical.

Definition at line 147 of file qsslcipher.cpp.

Here is the call graph for this function:

◆ operator=() [2/2]

QSslCipher& QSslCipher::operator= ( QSslCipher &&  other)
inlinenoexcept

Definition at line 64 of file qsslcipher.h.

Here is the call graph for this function:

◆ operator==()

bool QSslCipher::operator== ( const QSslCipher other) const

Returns true if this cipher is the same as other; otherwise, false is returned.

Definition at line 165 of file qsslcipher.cpp.

Here is the call graph for this function:

◆ protocol()

QSsl::SslProtocol QSslCipher::protocol ( ) const

Returns the cipher's protocol type, or \l QSsl::UnknownProtocol if QSslCipher is unable to determine the protocol (protocolString() may contain more information).

See also
protocolString()

Definition at line 257 of file qsslcipher.cpp.

Here is the caller graph for this function:

◆ protocolString()

QString QSslCipher::protocolString ( ) const

Returns the cipher's protocol as a QString.

See also
protocol()

Definition at line 245 of file qsslcipher.cpp.

Here is the caller graph for this function:

◆ supportedBits()

int QSslCipher::supportedBits ( ) const

Returns the number of bits supported by the cipher.

See also
usedBits()

Definition at line 201 of file qsslcipher.cpp.

◆ swap()

void QSslCipher::swap ( QSslCipher other)
inlinenoexcept
Since
5.0

Swaps this cipher instance with other. This function is very fast and never fails.

Definition at line 68 of file qsslcipher.h.

Here is the call graph for this function:

◆ usedBits()

int QSslCipher::usedBits ( ) const

Returns the number of bits used by the cipher.

See also
supportedBits()

Definition at line 211 of file qsslcipher.cpp.

Here is the caller graph for this function:

Friends And Related Function Documentation

◆ QTlsBackend

friend class QTlsBackend
friend

Definition at line 88 of file qsslcipher.h.


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