docs(security): adds data partition verification docs

This commit is contained in:
Ashish Sharma
2026-03-04 10:22:33 +08:00
parent f93575a622
commit abe0d37d94
4 changed files with 54 additions and 0 deletions
+17
View File
@@ -229,6 +229,23 @@ Kconfig 中的 :ref:`CONFIG_BOOTLOADER_APP_ROLLBACK_ENABLE` 可以帮助用户
具体可参考 :ref:`signed-app-verify`。
.. _secure-signed-data-partition:
签名数据分区的更新
------------------
数据分区镜像可以使用与应用镜像相同的 Secure Boot v2 签名机制进行验证。启用 :ref:`CONFIG_SECURE_SIGNED_DATA_PARTITION`,以便在 OTA 更新期间验证子类型为 ``ESP_PARTITION_SUBTYPE_DATA_UNDEFINED`` 的数据分区。
使用以下命令对数据分区镜像进行签名:
.. code-block:: bash
idf.py secure-sign-data --keyfile PRIVATE_SIGNING_KEY --output signed_data.bin data.bin
签名密钥必须与用于应用签名的密钥一致,并将其公钥摘要写入 eFuse。签名镜像格式为:数据内容(填充到 4 KB)+ 4 KB 签名块(参见 :doc:`/security/secure-boot-v2` 中的 :ref:`signature-block-format`)。
如需完整示例,请参见 :example:`system/ota/partitions_ota`。
OTA 性能调优
------------