You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
:kconfig:option:`CONFIG_GEN_UICR_SECURESTORAGE` enables the secure storage system used by |ISE| for persistent storage of cryptographic keys and trusted data.
707
707
The secure storage is divided into separate partitions for different services and processor domains.
708
-
The total size of all configurations specified in ``UICR.SECURESTORAGE.*`` must be aligned to a 4 KB boundary.
708
+
The total size of all configurations specified in UICR.SECURESTORAGE.\* must be aligned to a 4 KB boundary.
709
709
For more information, see :ref:`ug_nrf54h20_ironside_se_secure_storage`.
710
710
711
711
The UICR.SECURESTORAGE configuration consists of the following sub-registers:
@@ -769,10 +769,10 @@ For information on how to configure these UICR settings, see :ref:`ug_nrf54h20_i
769
769
770
770
.. _ug_nrf54h20_ironside_se_boot_report:
771
771
772
-
IronSide boot report
773
-
********************
772
+
|ISE| boot report
773
+
*****************
774
774
775
-
The IronSide boot report contains device state information communicated from |ISE| to the local domains.
775
+
The |ISE| boot report contains device state information communicated from |ISE| to the local domains.
776
776
It is written to a reserved region in RAM20, which is accessible to the local domain in the default system configuration.
777
777
There is one boot report per processor that is booted, either directly by |ISE| or via the CPUCONF service.
778
778
@@ -954,7 +954,7 @@ Setting bit 5 in ``CTRLAP.BOOTMODE`` will also trigger secondary firmware.
954
954
|ISE| automatically triggers the secondary firmware in any of the following situations:
955
955
956
956
* The integrity check of the memory specified in :kconfig:option:`CONFIG_GEN_UICR_PROTECTEDMEM` fails.
957
-
* Any boot failure occurs, such as missing primary firmware or failure to apply ``UICR.PERIPHCONF`` configurations.
957
+
* Any boot failure occurs, such as missing primary firmware or failure to apply UICR.PERIPHCONF configurations.
958
958
* If :kconfig:option:`CONFIG_GEN_UICR_SECONDARY_TRIGGER` is enabled, and a UICR-configurable trigger occurs.
959
959
See the following table for UICR-configurable triggers.
960
960
@@ -1067,21 +1067,21 @@ To leverage this secure storage functionality, applications must set the key loc
1067
1067
1068
1068
The secure storage configuration includes two separate storage regions:
1069
1069
1070
-
* **UICR.SECURESTORAGE.CRYPTO** - Used for PSA Crypto API operations when storing cryptographic keys
1071
-
* **UICR.SECURESTORAGE.ITS** - Used for PSA Internal Trusted Storage (ITS) API operations when storing general secure data
1070
+
* UICR.SECURESTORAGE.CRYPTO - Used for PSA Crypto API operations when storing cryptographic keys
1071
+
* UICR.SECURESTORAGE.ITS - Used for PSA Internal Trusted Storage (ITS) API operations when storing general secure data
1072
1072
1073
1073
1074
1074
Secure Storage through PSA Crypto API
1075
1075
=====================================
1076
1076
1077
-
When using the PSA Crypto API to operate on keys, the storage region specified by ``UICR.SECURESTORAGE.CRYPTO`` is automatically used if the key attributes are configured with **key location** set to ``PSA_KEY_LOCATION_LOCAL_STORAGE``.
1077
+
When using the PSA Crypto API to operate on keys, the storage region specified by UICR.SECURESTORAGE.CRYPTO is automatically used if the key attributes are configured with ``key location`` set to ``PSA_KEY_LOCATION_LOCAL_STORAGE``.
1078
1078
1079
1079
This ensures that cryptographic keys are stored in the dedicated secure storage region rather than in regular application memory.
1080
1080
1081
1081
Secure storage through PSA ITS API
1082
1082
==================================
1083
1083
1084
-
When using the PSA ITS API for storing general secure data, the storage region specified by ``UICR.SECURESTORAGE.ITS`` is used automatically.
1084
+
When using the PSA ITS API for storing general secure data, the storage region specified by UICR.SECURESTORAGE.ITS is used automatically.
1085
1085
No special configuration is required for PSA ITS operations, as they inherently use the secure storage when available.
1086
1086
1087
1087
Security Properties
@@ -1092,16 +1092,16 @@ The secure storage provided by |ISE| has the following security characteristics:
1092
1092
Access Control
1093
1093
--------------
1094
1094
1095
-
* **Domain Isolation**: Secure storage regions are not accessible by local domains directly.
1096
-
* **Ironside Exclusive Access**: Only the Ironside Secure Element can access the secure storage regions.
1097
-
* **Domain Separation**: Each local domain can only access its own secure storage data, ensuring isolation between different domains.
1095
+
* *Domain Isolation*: Secure storage regions are not accessible by local domains directly.
1096
+
* *Ironside Exclusive Access*: Only the |ISE| can access the secure storage regions.
1097
+
* *Domain Separation*: Each local domain can only access its own secure storage data, ensuring isolation between different domains.
1098
1098
1099
1099
Data Protection
1100
1100
---------------
1101
1101
1102
-
* **Encryption**: All data stored in the secure storage regions is encrypted using device-unique keys.
1103
-
* **Integrity**: The stored data is protected against tampering through cryptographic integrity checks.
1104
-
* **Confidentiality**: The encryption ensures that stored data remains confidential even if the storage medium is physically accessed.
1102
+
* *Encryption*: All data stored in the secure storage regions is encrypted using device-unique keys.
1103
+
* *Integrity*: The stored data is protected against tampering through cryptographic integrity checks.
1104
+
* *Confidentiality*: The encryption ensures that stored data remains confidential even if the storage medium is physically accessed.
1105
1105
1106
1106
.. note::
1107
1107
The device-unique encryption keys are managed entirely by |ISE| and are not accessible to application code.
When configuring secure storage, consider the following:
1114
1114
1115
-
* Ensure sufficient storage space is allocated in both ``UICR.SECURESTORAGE.CRYPTO`` and ``UICR.SECURESTORAGE.ITS`` regions based on your application's requirements
1115
+
* Ensure sufficient storage space is allocated in both UICR.SECURESTORAGE.CRYPTO and UICR.SECURESTORAGE.ITS regions based on your application's requirements
1116
1116
* The sum of these two regions must be 4kB aligned.
1117
1117
* The secure storage regions should be properly sized to accommodate the expected number of keys and data items
1118
1118
* Access to secure storage is only available when the key location is explicitly set to ``PSA_KEY_LOCATION_LOCAL_STORAGE``
@@ -1292,3 +1292,128 @@ This prevents the CPU from executing any instructions until the CPUWAIT register
1292
1292
Use this command to begin debugging at the very first instruction or to program flash memory safely without concurrent CPU access.
1293
1293
1294
1294
The ``DEBUGWAIT`` command does not define any command-specific values for the CTRLAP.BOOTSTATUS.CMDERROR field.
|ISE| configures the SPU.FEATURES.MRAMC registers with default settings for both MRAMC110 and MRAMC111.
1302
+
Local domains have access to the READY/READYNEXT status registers for monitoring the status of the MRAM controller.
1303
+
All other MRAMC features (like WAITSTATES and AUTODPOWERDOWN) are managed by |ISE|, with all configurations locked at boot time.
1304
+
1305
+
.. _ug_nrf54h20_ironside_se_counter_service:
1306
+
1307
+
|ISE| Counter service
1308
+
*********************
1309
+
1310
+
The |ISE| Counter service provides secure monotonic counters for rollback protection, version tracking, and other security-critical applications that require strictly increasing values.
1311
+
1312
+
The header file for this service is :file:`sdk-zephyr/soc/nordic/ironside/include/nrf_ironside/counter.h`.
1313
+
1314
+
It provides four independent 32-bit monotonic counters (``IRONSIDE_COUNTER_0`` through ``IRONSIDE_COUNTER_3``).
1315
+
Each counter can only be set to a value greater than or equal to its current value, which ensures that counter values never decrease.
1316
+
1317
+
The counters have the following properties:
1318
+
1319
+
.. list-table::
1320
+
:header-rows: 1
1321
+
1322
+
* - Property
1323
+
- Description
1324
+
* - Monotonic
1325
+
- Counter values can only increase or stay the same; they cannot decrease.
1326
+
* - Persistent
1327
+
- Counter values are stored in secure storage and survive reboots.
1328
+
* - Per-boot locking
1329
+
- Counters can be locked for the current boot session to prevent further modifications.
1330
+
* - Automatic initialization
1331
+
- Counters are initialized to 0 during the first boot with an unlocked UICR.
1332
+
1333
+
Operations
1334
+
==========
1335
+
1336
+
The Counter service provides three primary operations applicable to the counters: ``set``, ``get``, and ``lock``.
1337
+
1338
+
Set
1339
+
---
1340
+
1341
+
The ``ironside_counter_set()`` function sets a counter to a specified value.
1342
+
The new value must be greater than or equal to the current counter value.
1343
+
1344
+
The function takes the following parameters:
1345
+
1346
+
* ``counter_id`` - Counter identifier (``IRONSIDE_COUNTER_0`` through ``IRONSIDE_COUNTER_3``).
1347
+
* ``value`` - New counter value.
1348
+
It must be greater than or equal to the current value.
1349
+
1350
+
The function returns the following values:
1351
+
1352
+
* ``0`` on success.
1353
+
* ``-IRONSIDE_COUNTER_ERROR_INVALID_ID`` if the counter ID is invalid.
1354
+
* ``-IRONSIDE_COUNTER_ERROR_TOO_LOW`` if the specified value is lower than the current value.
1355
+
* ``-IRONSIDE_COUNTER_ERROR_LOCKED`` if the counter is locked for this boot session.
1356
+
* ``-IRONSIDE_COUNTER_ERROR_STORAGE_FAILURE`` if the storage operation failed.
1357
+
1358
+
Get
1359
+
---
1360
+
1361
+
The ``ironside_counter_get()`` function retrieves the current value of a counter.
1362
+
1363
+
The function takes the following parameters:
1364
+
1365
+
* ``counter_id`` - Counter identifier (``IRONSIDE_COUNTER_0`` through ``IRONSIDE_COUNTER_3``).
1366
+
* ``value`` - Pointer to store the retrieved counter value.
1367
+
1368
+
The function returns the following values:
1369
+
1370
+
* ``0`` on success.
1371
+
* ``-IRONSIDE_COUNTER_ERROR_INVALID_ID`` if the counter ID is invalid.
1372
+
* ``-IRONSIDE_COUNTER_ERROR_STORAGE_FAILURE`` if the storage operation failed or the counter is not initialized.
1373
+
1374
+
Lock
1375
+
----
1376
+
1377
+
The ``ironside_counter_lock()`` function locks a counter for the current boot session, which prevents any further modifications until the next reboot.
1378
+
Lock states are non-persistent and are cleared on reboot.
1379
+
1380
+
The function takes the following parameter:
1381
+
1382
+
* ``counter_id`` - Counter identifier (``IRONSIDE_COUNTER_0`` through ``IRONSIDE_COUNTER_3``).
1383
+
1384
+
The function returns the following values:
1385
+
1386
+
* ``0`` on success.
1387
+
* ``-IRONSIDE_COUNTER_ERROR_INVALID_ID`` if the counter ID is invalid.
1388
+
1389
+
Usage
1390
+
=====
1391
+
1392
+
The Counter service is typically used for the following purposes:
1393
+
1394
+
* *Firmware version tracking* - Store the current firmware version and prevent rollback to older versions.
1395
+
* *Anti-rollback protection* - Ensure that security-critical updates cannot be reverted.
0 commit comments