QSslEllipticCurve Class

Represents an elliptic curve for use by elliptic-curve cipher algorithms. 更多...

头: #include <QSslEllipticCurve>
qmake: QT += network
Since: Qt 5.5

该类在 Qt 5.5 引入。

注意: 此类的所有函数 可重入 .

公共函数

QSslEllipticCurve ()
bool isTlsNamedCurve () const
bool isValid () const
QString longName () const
QString shortName () const

静态公共成员

QSslEllipticCurve fromLongName (const QString & name )
QSslEllipticCurve fromShortName (const QString & name )
bool operator!= (QSslEllipticCurve lhs , QSslEllipticCurve rhs )
QDebug operator<< (QDebug debug , QSslEllipticCurve curve )
bool operator== (QSslEllipticCurve lhs , QSslEllipticCurve rhs )

详细描述

The class QSslEllipticCurve represents an elliptic curve for use by elliptic-curve cipher algorithms.

Elliptic curves can be constructed from a "short name" (SN) ( fromShortName ()), and by a call to QSslConfiguration::supportedEllipticCurves ().

QSslEllipticCurve instances can be compared for equality and can be used as keys in QHash and QSet . They cannot be used as key in a QMap .

注意: This class is currently only supported in OpenSSL.

成员函数文档编制

QSslEllipticCurve:: QSslEllipticCurve ()

Constructs an invalid elliptic curve.

另请参阅 isValid () 和 QSslConfiguration::supportedEllipticCurves ().

[static] QSslEllipticCurve QSslEllipticCurve:: fromLongName (const QString & name )

返回 QSslEllipticCurve instance representing the named curve namename is a long name for the curve, whose exact spelling depends on the SSL implementation.

若给定 name is not supported, returns an invalid QSslEllipticCurve 实例。

注意: The OpenSSL implementation of this function treats the name case-sensitively.

另请参阅 longName ().

[static] QSslEllipticCurve QSslEllipticCurve:: fromShortName (const QString & name )

返回 QSslEllipticCurve instance representing the named curve namename is the conventional short name for the curve, as represented by RFC 4492 (for instance secp521r1 ), or as NIST short names (for instance P-256 ). The actual set of recognized names depends on the SSL implementation.

若给定 name is not supported, returns an invalid QSslEllipticCurve 实例。

注意: The OpenSSL implementation of this function treats the name case-sensitively.

另请参阅 shortName ().

bool QSslEllipticCurve:: isTlsNamedCurve () const

Returns true if this elliptic curve is one of the named curves that can be used in the key exchange when using an elliptic curve cipher with TLS; false otherwise.

bool QSslEllipticCurve:: isValid () const

Returns true if this elliptic curve is a valid curve, false otherwise.

QString QSslEllipticCurve:: longName () const

Returns the conventional long name for this curve. If this curve is invalid, returns an empty string.

另请参阅 shortName ().

QString QSslEllipticCurve:: shortName () const

Returns the conventional short name for this curve. If this curve is invalid, returns an empty string.

另请参阅 longName ().

相关非成员

bool operator!= ( QSslEllipticCurve lhs , QSslEllipticCurve rhs )

Returns true if the curve lhs represents a different curve than rhs ; false otherwise.

该函数在 Qt 5.5 引入。

QDebug operator<< ( QDebug debug , QSslEllipticCurve curve )

Writes the elliptic curve curve 到 debug 对象 debug 为调试目的。

该函数在 Qt 5.5 引入。

另请参阅 调试技术 .

bool operator== ( QSslEllipticCurve lhs , QSslEllipticCurve rhs )

Returns true if the curve lhs represents the same curve of rhs ;

该函数在 Qt 5.5 引入。