6#include <QtCore/qbytearray.h>
7#include <QtCore/qdatastream.h>
8#include <QtCore/qmessageauthenticationcode.h>
9#include <QtCore/qrandom.h>
11#include <QtNetwork/private/qsslsocket_p.h>
12#include <QtNetwork/private/qsslkey_p.h>
51 char *
p = passUnicode.
data();
52 for (
int i = 0;
i < passPhrase.
size(); ++
i) {
54 *(
p++) = (
ch & 0xff00) >> 8;
61 const int sSize =
v * ((salt.
size() +
v - 1) /
v);
63 for (
int i = 0;
i < sSize; ++
i)
64 S[
i] = salt[
i % salt.
size()];
65 const int pSize =
v * ((passUnicode.
size() +
v - 1) /
v);
67 for (
int i = 0;
i < pSize; ++
i)
68 P[
i] = passUnicode[
i % passUnicode.
size()];
72 const int c = (
n + u - 1) / u;
76 for (
int i = 0;
i <
c; ++
i) {
79 for (
int j = 0;
j <
r; ++
j)
82 for (
int j = 0;
j <
v; ++
j)
86 for (
int p = 0;
p < I.size();
p +=
v) {
88 for (
int j =
v - 1;
j >= 0; --
j) {
91 carry = (
v & 0xff00) >> 8;
103 for (
int i = 0;
i < salt.
size(); ++
i)
156 const int iterations = 2048;
205 for (
int i = 0;
i <
certs.size(); ++
i)
224 const int iterations = 2048;
static QAsn1Element fromVector(const QList< QAsn1Element > &items)
static QAsn1Element fromObjectId(const QByteArray &id)
void write(QDataStream &data) const
static QAsn1Element fromInteger(unsigned int val)
char * data()
\macro QT_NO_CAST_FROM_BYTEARRAY
qsizetype size() const noexcept
Returns the number of bytes in this byte array.
void resize(qsizetype size)
Sets the size of the byte array to size bytes.
static QByteArray hash(QByteArrayView data, Algorithm method)
Returns the hash of data using method.
\inmodule QtCore\reentrant
void addData(const char *data, qsizetype length)
This is an overloaded member function, provided for convenience. It differs from the above function o...
QByteArray result() const
Returns the final authentication code.
static Q_DECL_CONST_FUNCTION QRandomGenerator * global()
\threadsafe
The QSslCertificate class provides a convenient API for an X509 certificate.
static Q_NETWORK_EXPORT QByteArray encrypt(Cipher cipher, const QByteArray &data, const QByteArray &key, const QByteArray &iv)
The QSslKey class provides an interface for private and public keys.
\macro QT_RESTRICTED_CAST_FROM_ASCII
qsizetype size() const
Returns the number of characters in this string.
const QChar * unicode() const
Returns a Unicode representation of the string.
Combined button and popup list for selecting options.
#define DSA_ENCRYPTION_OID
#define RSA_ENCRYPTION_OID
EGLOutputLayerEXT EGLint EGLAttrib value
[5]
GLsizei const GLfloat * v
[13]
GLint GLsizei GLsizei GLenum GLenum GLsizei void * data
static QByteArray _q_PKCS12_salt()
static QAsn1Element _q_PKCS7_data(const QByteArray &data)
QByteArray _q_makePkcs12(const QList< QSslCertificate > &certs, const QSslKey &key, const QString &passPhrase)
static QByteArray _q_PKCS12_bag(const QList< QSslCertificate > &certs, const QSslKey &key, const QString &passPhrase)
static QByteArray _q_PKCS12_certBag(const QSslCertificate &cert)
static QByteArray _q_PKCS12_shroudedKeyBag(const QSslKey &key, const QString &passPhrase, const QByteArray &localKeyId)
static QAsn1Element _q_PKCS12_mac(const QByteArray &data, const QString &passPhrase)
static QByteArray _q_PKCS12_keygen(char id, const QByteArray &salt, const QString &passPhrase, int n, int r)
PKCS #12 key derivation.
static QAsn1Element _q_PKCS12_key(const QSslKey &key)
static QT_BEGIN_NAMESPACE QAsn1Element wrap(quint8 type, const QAsn1Element &child)
QList< QSslCertificate > cert
[0]