Skip to content

Commit b32e031

Browse files
committed
doc: tfm: move overview to a separate page
Moved the Overview section of the TF-M doc to a separate page. Moved the PSA Certified API page one level up. Added information about security services supported by minimal build. NCSDK-32307, NCSDK-15032, and NCSDK-9188. Signed-off-by: Grzegorz Ferenc <Grzegorz.Ferenc@nordicsemi.no>
1 parent 87a79a5 commit b32e031

11 files changed

+255
-69
lines changed

doc/nrf/links.txt

+5-1
Original file line numberDiff line numberDiff line change
@@ -235,6 +235,9 @@
235235
.. _`crypto.h`: https://github.com/nrfconnect/sdk-trusted-firmware-m/blob/master/interface/include/psa/crypto.h
236236
.. _`protected_storage.h`: https://github.com/nrfconnect/sdk-trusted-firmware-m/blob/master/interface/include/psa/protected_storage.h
237237
.. _`initial_attestation.h`: https://github.com/nrfconnect/sdk-trusted-firmware-m/blob/main/interface/include/psa/initial_attestation.h.in
238+
.. _`tfm_platform_api.h`: https://github.com/nrfconnect/sdk-trusted-firmware-m/blob/main/interface/include/tfm_platform_api.h
239+
.. _`tfm_ioctl_core_api.h`: https://github.com/nrfconnect/sdk-trusted-firmware-m/blob/main/platform/ext/target/nordic_nrf/common/core/services/include/tfm_ioctl_core_api.h
240+
.. _`tfm_ioctl_api.h`: https://github.com/nrfconnect/sdk-nrf/blob/main/include/tfm/tfm_ioctl_api.h
238241

239242
.. ### Source: arm-software.github.io, armmbed.github.io
240243

@@ -245,8 +248,8 @@
245248
.. _`Key Identifiers`: https://arm-software.github.io/psa-api/crypto/1.1/api/keys/ids.html#key-identifiers
246249
.. _`Keystore Interface`: https://arm-software.github.io/psa-api/crypto/1.1/overview/goals.html#a-keystore-interface
247250
.. _`PSA Cryptography API 1.0.1`: https://armmbed.github.io/mbed-crypto/1.0.1/html/index.html
251+
.. _`PSA Certified Crypto API 1.0.0`: https://arm-software.github.io/psa-api/crypto/1.0/IHI0086-PSA_Cryptography_API-1.0.0.pdf
248252
.. _`PSA Certified Crypto API 1.2.1`: https://arm-software.github.io/psa-api/crypto/1.2/
249-
.. _`PSA Certified Crypto API 1.2 PAKE Extension Final 1`: https://arm-software.github.io/psa-api/crypto/1.2/ext-pake/
250253
.. _`PSA functions for key management`: https://arm-software.github.io/psa-api/crypto/1.1/api/keys/management.html
251254

252255
.. _`PSA Certified Secure Storage API`: https://arm-software.github.io/psa-api/storage/
@@ -485,6 +488,7 @@
485488
.. _`TF-M Secure Interrupt Integration`: https://docs.nordicsemi.com/bundle/ncs-latest/page/tfm/integration_guide/tfm_secure_irq_integration_guide.html
486489
.. _`TF-M Secure Partition Manager`: https://docs.nordicsemi.com/bundle/ncs-latest/page/tfm/design_docs/services/secure_partition_manager.html
487490
.. _`TF-M Inter-Process Communication`: https://docs.nordicsemi.com/bundle/ncs-latest/page/tfm/design_docs/services/tfm_psa_inter_process_communication.html
491+
.. _`FF-M Isolation Rules`: https://docs.nordicsemi.com/bundle/ncs-latest/page/tfm/design_docs/ff_isolation.html
488492

489493
.. _`HCI Events`: https://docs.nordicsemi.com/bundle/ncs-latest/page/nrfxlib/softdevice_controller/doc/api.html#hci_events
490494

doc/nrf/releases_and_maturity/releases/release-notes-changelog.rst

+1
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,7 @@ Security
142142
* Support for Ed25519ph(HashEdDSA) to CRACEN.
143143
* Documentation page about the :ref:`ug_tfm_architecture`.
144144
* Documentation page about the :ref:`ug_psa_certified_api_overview`.
145+
* Documentation page about the :ref:`ug_tfm_supported_services`.
145146

146147
* Updated:
147148

doc/nrf/releases_and_maturity/software_maturity.rst

+9-3
Original file line numberDiff line numberDiff line change
@@ -1930,11 +1930,13 @@ Trusted Firmware-M support
19301930

19311931
.. toggle::
19321932

1933+
.. tfm_ncs_profiles_support_table_start
1934+
19331935
.. list-table::
19341936
:widths: auto
19351937
:header-rows: 1
19361938

1937-
* -
1939+
* - Profile
19381940
- nRF52810
19391941
- nRF52811
19401942
- nRF52820
@@ -1950,7 +1952,7 @@ Trusted Firmware-M support
19501952
- nRF9151
19511953
- nRF9160
19521954
- nRF9161
1953-
* - **Full build**
1955+
* - :ref:`Configurable <ug_tfm_supported_services_profiles_configurable>`
19541956
- --
19551957
- --
19561958
- --
@@ -1966,7 +1968,7 @@ Trusted Firmware-M support
19661968
- Experimental
19671969
- Experimental
19681970
- Experimental
1969-
* - **Minimal Build**
1971+
* - :ref:`Minimal <ug_tfm_supported_services_profiles_minimal>`
19701972
- --
19711973
- --
19721974
- --
@@ -1985,6 +1987,10 @@ Trusted Firmware-M support
19851987

19861988
| [1]: The attestation service is not supported.
19871989
1990+
.. tfm_ncs_profiles_support_table_end
1991+
1992+
For more information about supported TF-M features in the |NCS|, see :ref:`ug_tfm_supported_services`.
1993+
19881994
.. _software_maturity_security_features_psa:
19891995

19901996
PSA Crypto support

doc/nrf/security.rst

+1
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ Some of them are documented in detail in other parts of this documentation, whil
6464
:maxdepth: 2
6565
:caption: Subpages:
6666

67+
security/psa_certified_api_overview
6768
security/ap_protect
6869
security/tfm/index
6970
security/trusted_storage

doc/nrf/security/tfm/psa_certified_api_overview.rst doc/nrf/security/psa_certified_api_overview.rst

+28
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,34 @@ Using the PSA Certified APIs has the following benefits:
4545
* Flexible and scalable - The various use cases supported ensure that the PSA Certified APIs can be used across multiple devices, from very simple ones to more complex systems.
4646
* Future-proof - PSA Certified APIs are designed to be updated over time as security threats evolve, ensuring that devices remain secure throughout their lifecycle.
4747

48+
.. _ug_psa_certified_api_overview_supported_apis:
49+
50+
Supported PSA Certified APIs
51+
============================
52+
53+
The following table provides an overview of the PSA Certified APIs support status in the |NCS|:
54+
55+
.. list-table:: PSA Certified APIs support in the |NCS|
56+
:header-rows: 1
57+
:widths: auto
58+
59+
* - PSA Certified API
60+
- Support status in the |NCS|
61+
- Latest version supported
62+
* - `PSA Certified Crypto API`_
63+
- Supported
64+
- | `PSA Certified Crypto API 1.2.1`_ for :ref:`nRF54L cryptography <ug_nrf54l_cryptography>` and :ref:`nrf_security` builds without TF-M
65+
| `PSA Certified Crypto API 1.0.0`_ for builds with TF-M
66+
* - `PSA Certified Attestation API`_
67+
- Supported
68+
- `PSA Certified Attestation API 1.0`_
69+
* - `PSA Certified Secure Storage API`_
70+
- Supported
71+
- `PSA Certified Secure Storage API 1.0`_
72+
* - `PSA Certified Firmware Update API`_
73+
- Not supported
74+
- n/a
75+
4876
.. _ug_psa_certified_api_overview_crypto:
4977

5078
PSA Crypto API

doc/nrf/security/tfm/index.rst

+13-9
Original file line numberDiff line numberDiff line change
@@ -12,26 +12,30 @@ Nordic Semiconductor recommends following `Platform Security Architecture (PSA)`
1212
Trusted Firmware-M (TF-M) is the reference implementation of PSA, which follows `PSA Certified IoT Security Framework`_ for securing connected devices.
1313
For more information about the framework, see the :ref:`ug_psa_certified_api_overview` page.
1414

15-
TF-M provides a reference design of a Secure Processing Environment (SPE) for Arm M-profile architectures.
16-
The SPE relies on security by separation to protect sensitive assets and code.
17-
TF-M also provides security services to the application, such as Protected Storage, Cryptography, and Attestation.
15+
TF-M provides a reference design of a Trusted Execution Environment (TEE) for Arm M-profile architectures.
16+
Using a highly configurable set of software components, it creates the Secure Processing Environment (SPE), which relies on security by separation to protect sensitive assets and code.
17+
TF-M also provides a set of secure runtime services to the application, such as Protected Storage, Cryptography, and Attestation.
18+
Additionally, secure boot through MCUboot in TF-M ensures integrity of runtime software and supports firmware upgrade.
1819

1920
`ARM TrustZone`_ technology included in Nordic Semiconductor's SoCs that implement the Armv8-M architecture (such as nRF5340, the nRF54L Series or the nRF91 Series) provides hardware-enforced separation of the Secure and Non-secure Processing Environments (SPE and NSPE, respectively) into Trusted and Non-Trusted worlds.
2021

22+
The TF-M implementation in the |NCS| is demonstrated in the following samples:
23+
24+
* All :ref:`tfm_samples` in this SDK
25+
* All :ref:`cryptography samples <crypto_samples>` in this SDK
26+
* A series of :zephyr:code-sample-category:`tfm_integration` samples available in Zephyr (these include :ref:`ug_tfm_supported_services_tfm_services` from the |NCS| when they are built from the |NCS| context)
27+
2128
Starting from the |NCS| v2.0.0, TF-M is enabled by default for applications and samples that support hardware-enforced separation of the SPE and the NSPE.
29+
In addition, the TF-M implementation is used in all samples and applications in this SDK that support the ``*/ns`` :ref:`variant <app_boards_names>` of the boards, due to :ref:`Cortex-M Security Extensions (CMSE) <app_boards_spe_nspe>` support.
2230

2331
The pages in this section describe the architecture and configuration of TF-M in the |NCS|.
24-
For more information about TF-M, see the `Trusted Firmware-M documentation <TF-M documentation_>`_, which is oriented towards TF-M developers.
25-
26-
.. important::
27-
Currently, only the :ref:`Minimal TF-M configuration <tfm_minimal_build>` is :ref:`supported <software_maturity_security_features_tfm>` in the |NCS|.
28-
Configuring TF-M to use features beyond the minimal configuration (with so called :ref:`tfm_configurable_build`) is :ref:`experimental <software_maturity_security_features_tfm>`.
32+
For more information about TF-M, see the `Trusted Firmware-M documentation <TF-M documentation_>`_, which is oriented towards TF-M implementation developers.
2933

3034
.. toctree::
3135
:maxdepth: 2
3236
:caption: Subpages:
3337

38+
tfm_supported_services
3439
tfm_architecture
3540
processing_environments
36-
psa_certified_api_overview
3741
tfm

doc/nrf/security/tfm/tfm.rst

+15-51
Original file line numberDiff line numberDiff line change
@@ -9,46 +9,10 @@ Configuring applications for Trusted Firmware-M
99

1010
On nRF5340, nRF54L15 and nRF91 Series devices, Trusted Firmware-M (TF-M) is used to configure and boot an application as non-secure.
1111

12-
Overview
13-
********
12+
.. _ug_tfm_building:
1413

15-
TF-M is the reference implementation of `Platform Security Architecture (PSA)`_.
16-
17-
It provides a highly configurable set of software components to create a Trusted Execution Environment.
18-
This is achieved by a set of secure run time services such as Secure Storage, Cryptography, Audit Logs, and Attestation.
19-
Additionally, secure boot through MCUboot in TF-M ensures integrity of runtime software and supports firmware upgrade.
20-
21-
.. note::
22-
Only the TF-M :ref:`minimal build <tfm_minimal_build>` implementation in the |NCS| is currently :ref:`supported <software_maturity_security_features_tfm>`.
23-
Support for TF-M with minimal version *disabled* in the |NCS| is :ref:`experimental <software_maturity_security_features_tfm>`.
24-
25-
For official documentation, see the `TF-M documentation`_.
26-
27-
The TF-M implementation in |NCS| is demonstrated in the following samples:
28-
29-
* All :ref:`tfm_samples` in this SDK
30-
* All :ref:`cryptography samples <crypto_samples>` in this SDK
31-
* A series of :zephyr:code-sample-category:`tfm_integration` samples available in Zephyr
32-
33-
In addition, the TF-M implementation is used in all samples and applications in this SDK that support the ``*/ns`` :ref:`variant <app_boards_names>` of the boards, due to :ref:`Cortex-M Security Extensions (CMSE) <app_boards_spe_nspe>` support.
34-
35-
Limitations
36-
===========
37-
38-
The following limitations apply to TF-M and its usage:
39-
40-
* Firmware Update service is not supported.
41-
* The following crypto modules or ciphers are not supported:
42-
43-
* AES output feedback (AES-OFB) mode.
44-
* AES cipher feedback (AES-CFB) mode.
45-
46-
* Isolation level 3 is not supported.
47-
* In Isolation level 2 (and 3), the number of peripherals configured as secure in Application Root of Trust (ARoT) is limited by the number of available MPU regions.
48-
* Nordic Semiconductor devices only support the GCC toolchain for building TF-M.
49-
50-
Building
51-
********
14+
Building with TF-M
15+
******************
5216

5317
TF-M is one of the images that are built as part of a multi-image application.
5418

@@ -85,18 +49,13 @@ See :ref:`tfm_partition_crypto` for more information about the TF-M Crypto parti
8549
Minimal build
8650
=============
8751

88-
The default configuration of TF-M has all supported features enabled, which results in a significant memory footprint.
89-
For this reason, the |NCS| provides a minimal version of the TF-M secure application, which shows how to configure a reduced version of TF-M.
90-
91-
The secure services supported by this minimal version allow for:
52+
.. include:: tfm_supported_services.rst
53+
:start-after: minimal_build_overview_start
54+
:end-before: minimal_build_overview_end
9255

93-
* Generating random numbers using the CryptoCell peripheral.
94-
* Using the :ref:`platform services <ug_tfm_services_platform>`.
95-
* Reading secure memory from the non-secure application (strictly restricted to a list of allowed addresses).
96-
Depending on the device, this lets you read metadata in the bootloader, verify FICR or UICR values, or access a peripheral that is secure-only.
97-
* Rebooting from the non-secure side.
56+
The minimal build uses an image of around 32 kB.
57+
It is set with the :kconfig:option:`CONFIG_TFM_PROFILE_TYPE_MINIMAL` Kconfig option that is enabled by default on the nRF53 and nRF91 Series devices.
9858

99-
The minimal version is set with the :kconfig:option:`CONFIG_TFM_PROFILE_TYPE_MINIMAL` Kconfig option, which is enabled by default on the nRF53 Series and nRF91 Series devices.
10059
With the minimal build, the configuration of TF-M is severely limited.
10160
Hence, it is not possible to modify the TF-M minimal configuration to create your own variant of the minimal configuration.
10261
Instead, the default configuration must be used as a starting point.
@@ -106,8 +65,9 @@ Instead, the default configuration must be used as a starting point.
10665
Configurable build
10766
==================
10867

109-
The configurable build is the full TF-M implementation that lets you configure all of its features.
110-
It does not come with the constraints of the minimal build.
68+
.. include:: tfm_supported_services.rst
69+
:start-after: configurable_build_overview_start
70+
:end-before: configurable_build_overview_end
11171

11272
To enable the configurable, full TF-M build, make sure the following Kconfig options are configured:
11373

@@ -379,6 +339,8 @@ See :ref:`lib_tfm_ioctl_api` for more information about APIs available for the n
379339

380340
For more information about the general features of the TF-M Platform partition, see `TF-M Platform`_.
381341

342+
.. _ug_tfm_services_its:
343+
382344
Internal Trusted Storage service
383345
================================
384346

@@ -721,6 +683,8 @@ The available space for the non-secure application has increased by 0x10000 byte
721683

722684
For devices that are intended for production and meant to be updated in the field, you should always use static partitions to ensure that the partitions are not moved around in the flash memory.
723685

686+
.. _ug_tfm_services_initial_attestation:
687+
724688
Initial Attestation service
725689
===========================
726690

doc/nrf/security/tfm/tfm_architecture.rst

+6-5
Original file line numberDiff line numberDiff line change
@@ -161,17 +161,17 @@ Isolation Levels
161161
The TF-M architecture figure at the top of this page uses several lines as connectors and separators.
162162
These lines represent the isolation levels between different parts of the SPE and between the SPE and the NSPE.
163163

164-
The following table describes the isolation levels in the TF-M architecture, based on the `Trusted Base System Architecture for M (TBSA-M) Specification`_ (section 4.3).
164+
The following table describes the isolation levels in the TF-M architecture, based on the `Trusted Base System Architecture for M (TBSA-M) Specification`_ (section 4.3) and the `FF-M Isolation Rules`_.
165165

166166
.. list-table::
167167
:header-rows: 1
168168

169169
* - Isolation Level
170170
- Description
171171
* - Level 1
172-
- | SPE isolation
172+
- | Two security domains
173173
|
174-
| Two security domains
174+
| SPE isolation
175175
|
176176
| SPE is protected from access by Non-Secure application firmware and hardware.
177177
* - Level 2
@@ -181,9 +181,9 @@ The following table describes the isolation levels in the TF-M architecture, bas
181181
|
182182
| In addition to Level 1, the Platform RoT is also protected from access by the Application RoT.
183183
* - Level 3
184-
- | Maximum firmware isolation
184+
- | Three or more security domains
185185
|
186-
| Three or more security domains
186+
| Maximum firmware isolation
187187
|
188188
| In addition to Level 2, each Secure Partition is sandboxed and only permitted to access its own resources.
189189
| This protects each Secure Partition from access by other Secure Partitions and protects the SPM from access by any Secure Partition.
@@ -193,3 +193,4 @@ In other words:
193193
* Level 1 Isolation is the Secure/Non-Secure separation described in the :ref:`ug_tfm_architecture_spe_nspe` section.
194194
* Level 2 Isolation means that the :ref:`ug_tfm_architecture_rot_services_application` are *unable* to access other parts of the SPE.
195195
* Level 3 Isolation means that the Application RoT Services are unable to access other parts of the SPE *and* other Application RoT Services.
196+
Level 3 Isolation is :ref:`not supported <ug_tfm_supported_services_isolation>` in the |NCS|.

0 commit comments

Comments
 (0)