MQTTS Custom CERTs

Hi,

I have been working with the nrf7002DK, I have a situation:

I have properly implemented Wi-Fi STA and MQTT over TLS. I want to update few things and would need your support.

1. In nrf7002DK overlay.conf, the certificate credentials are automatically provisioned, but I would want to read the credentials from a different location.

2. I want to enable and disable the TLS support during run time, i.e, Is it possible to edit/configure the .conf file from the source.c file.

Kindly respond in the earliest.

Kind Regards,

Lalith RJ

Parents
  • Hi

    Is there a specific reason you want to get the MQTTS certificates from NVS instead of automatically? 

    If you want to do this manually, you can "borrow" the certificates_provision() function from the mqtt_helper.c and use that to find another way to get the certificates. 

    Alternatively you can "invent the wheel" yourself, by creating a function where you load certificates into a buffer, then call tls_credential_add to put use your credentials.

    We don't have an exact way to get them manually, so you'll need to do some tweaking on your end.

    Best regards,

    Simon

Reply
  • Hi

    Is there a specific reason you want to get the MQTTS certificates from NVS instead of automatically? 

    If you want to do this manually, you can "borrow" the certificates_provision() function from the mqtt_helper.c and use that to find another way to get the certificates. 

    Alternatively you can "invent the wheel" yourself, by creating a function where you load certificates into a buffer, then call tls_credential_add to put use your credentials.

    We don't have an exact way to get them manually, so you'll need to do some tweaking on your end.

    Best regards,

    Simon

Children
Related