mirror of
https://github.com/yuzu-mirror/mbedtls.git
synced 2026-04-04 14:08:39 +00:00
psa: Implement persistent keys
Allow use of persistent keys, including configuring them, importing and
exporting them, and destroying them.
When getting a slot using psa_get_key_slot, there are 3 scenarios that
can occur if the keys lifetime is persistent:
1. Key type is PSA_KEY_TYPE_NONE, no persistent storage entry:
- The key slot is treated as a standard empty key slot
2. Key type is PSA_KEY_TYPE_NONE, persistent storage entry exists:
- Attempt to load the key from persistent storage
3. Key type is not PSA_KEY_TYPE_NONE:
- As checking persistent storage on every use of the key could
be expensive, the persistent key is assumed to be saved in
persistent storage, the in-memory key is continued to be used.
This commit is contained in:
parent
40225ba709
commit
d49a499d03
9 changed files with 599 additions and 5 deletions
|
|
@ -158,6 +158,8 @@ TEST_FILES := \
|
|||
tests/suites/test_suite_psa_crypto_hash.function \
|
||||
tests/suites/test_suite_psa_crypto_metadata.data \
|
||||
tests/suites/test_suite_psa_crypto_metadata.function \
|
||||
tests/suites/test_suite_psa_crypto_persistent_key.data \
|
||||
tests/suites/test_suite_psa_crypto_persistent_key.function \
|
||||
tests/suites/test_suite_psa_crypto_storage_file.data \
|
||||
tests/suites/test_suite_psa_crypto_storage_file.function \
|
||||
# Don't delete this line.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue