Hi,
Out of several Thingies 91 that we programmed with our software and security keys/tags two of them that had their battery drained seem to have lost their security tags.
The hardware version is 1.0.2 and software is based on SDK 1.3.1 (or perhaps it was 1.3.0).
The application does the following:
On startup, it forces deletion of all 5 keys in SEC_TAG 1 (calling it 1, 2, 3 for sake of example, but they are 5-digit unique tags) and programs CA Cert #1 for HTTP connection #1
On startup, it forces deletion of all 5 keys in SEC_TAG 2 and programs CA Cert #2 for HTTP connection #2
It makes use of, but does not modify keys in SEC_TAG 3, which contain CA Cert #3, device private key and cert for the MQTT connection. Each device has been previously provisioned with with these certs and keys with nRF Connect's LTE Link Monitor Security programming feature.
Once it starts, it connects MQTT and sends some data for 5 minutes.
After 5 minutes, it disconnects MQTT and disconnects form the carrier (lte_lc_offline)
If a button is pressed, the board reboots and repeats the above steps.
The power was drained over the course of perhaps several weeks when our team members just left the device on in LTE offline mode and likely cycled the app with a button press.
The boards that had issues have both been able to connect to MQTT previously multiple times. After the power drain, the MQTT connection stopped working and connect() was retiring -95, which indicates the keys missing. We have reviewed the SEC_TAG list on the modem and found the SEC_TAG 3 missing.
After re-reprogramming the SEC_TAG_3 certs and keys, the devices started working normally again.
We have since modified our app to not reprogram existing SEC_TAG 1 and 2 upon startup in hopes that it was the actual writes to SEC_TAG 1 and 2 that caused SEC_TAG3 to be lost. I wonder if anyone observed something similar and if you can provide any insights into the problem. I was not able to find a similar problem or a solution on the forums.
Thanks,
Nik