Hello,
Our product has two pieces of information that must be programmed during production: a shared secret key (128 bits) and a public, unique device identifier, also 128 bits.
For our application, it is sufficient to store this information in the nRF9160 internal flash and use APPROTECT UICR bit to prevent reading from the outside.
The simplest approach to storing these two pieces of information appears to be the Zephyr Non-Volatile Storage.
But I have two practical questions:
1. after setting the APPROTECT bit, can a non-secure application read/write from/to flash ?
2. is it possible to populate the NVS sector without using the application ? By this I mean, in production can we write the device unique key and ID
directly to the NVS sector ? If so, what is the format of the data, in this case ?