Set root certs
By default the device is configured to trust “Nabto Root CA 1”. This behavior can be overridden by the following function. All trusted root certs should be in the string and be encoded as PEM. The certs are copied into the device so the string can be freed after the call.
Root certs are used to validate the connection to the basestation.
NABTO_DEVICE_DECL_PREFIX NabtoDeviceError NABTO_DEVICE_API nabto_device_set_root_certs(NabtoDevice* device, const char* roots)
- [in] The device
- [in] Root certs encoded as pem.
NABTO_DEVICE_EC_OK iff ok NABTO_DEVICE_INVALID_STATE if device is started