QT-mosquittopp use tls method
I want to use raspberrypi qt mqtt client, in the process I have joined tls. But I can not connect to mosquitto. I use the command was successfully transferred.
This is my mosquitto.conf
log_dest file /var/log/mosquitto/mosquitto.log
Here is the code
QByteArray host = ui->lineIP->text().toLocal8Bit();
QByteArray id = ui->lineID->text().toLocal8Bit();
QByteArray pwd = ui->lineEdit->text().toLocal8Bit();
QByteArray pws = ui->lineEdit_2->text().toLocal8Bit();
port = ui->linePort->text().toInt();
mosq = new qtmosq(id, false);
connect (mosq, SIGNAL(connectEnable()), this, SLOT(connectEnabled()));
connect (mosq, SIGNAL(subscribed()), this ,SLOT(subscribed()));
connect (mosq, SIGNAL(connected()), this, SLOT(connected()));
connect (mosq, SIGNAL(messageSent(bool)), this, SLOT(setMessageStatus(bool)));
connect (mosq, SIGNAL(messageReceived(QString)), this, SLOT(showMessage(QString)));
How can I use tls through mosquittopp.h?Is there anything I made wrong?I need your recommendations to solve this issue.Thank you
That's a question you should ask the author of that library.
Or maybe consider using the official QtMqtt module.
@SGaist Thank you a lot,I will try to found method in your link.