简体   繁体   中英

QSslSocket: cannot resolve SSLV2_client_method

I have created a sslclient and sslserver using QSslSocket in Qt 5.4.1 in debian wheezy. When I run the program they dont work at all. After debuging my code I saw when it try to create a new object from QSslSocket it return this error ( cannot resolve SSLV2_client_method ) in constractor.

this is block of my code:

SSlClient::SSlClient(QObject *parent) : QObject(parent)
{
    client = new QSslSocket(this);
    client->setProtocol(QSsl::SslV3);

    connect(client, SIGNAL(encrypted()), this, SLOT(startTransfer()));
    connect(client, SIGNAL(encryptedBytesWritten(qint64)), this, SLOT(byteWritten()));


}

通过将openssl编译为共享库解决了这个问题。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM