Using MQTT helper library for TLS

Hi,

in Cellular Iot Fundamentals there is in lesson 4 an exercise to move to MQTT with TLS.

As I used MQTT helper library, I wonder if it is enough to modify the structure

struct mqtt_helper_conn_params conn_params = {
.hostname = CONFIG_MQTT_BROKER_HOSTNAME,
.port = CONFIG_MQTT_BROKER_PORT,
.transport.type = MQTT_TRANSPORT_SECURE,
.transport.tls.sec_tag = CONFIG_MQTT_TLS_SEC_TAG,
.transport.tls.hostname = CONFIG_MQTT_BROKER_HOSTNAME,
.transport.tls.peer_verify = TLS_PEER_VERIFY_REQUIRED,
};
to have a secure connection , anyway providing certificate as described in the example.
Thanks in advance for reply 
Best Regards

Parents Reply Children
Related