Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add DRBG test components #67

Open
8 tasks
ronald-cron-arm opened this issue Sep 28, 2023 · 0 comments
Open
8 tasks

Add DRBG test components #67

ronald-cron-arm opened this issue Sep 28, 2023 · 0 comments
Labels
enhancement New feature or request size-s Estimated task size: small (~2d)

Comments

@ronald-cron-arm
Copy link
Contributor

ronald-cron-arm commented Sep 28, 2023

  • Add PSA_CRYPTO_ENTROPY_FORCE_SHA256 config option and its documentation in the section "PSA cryptography core configuration options" of crypto_config.h. Similar to MBEDTLS_ENTROPY_FORCE_SHA256 in mbedtls. Disabled by default.
  • Add PSA_CRYPTO_CTR_DRBG_USE_128_BIT_KEY config option and its documentation in the section "PSA cryptography core configuration options" of crypto_config.h. Similar to MBEDTLS_CTR_DRBG_USE_128_BIT_KEY in mbedtls. Disabled by default.
  • Take into account PSA_CRYPTO_ENTROPY_FORCE_SHA256 and PSA_CRYPTO_CTR_DRBG_USE_128_BIT_KEY in RNG/DRBG pre-processor logic (see #if defined(PSA_CRYPTO_EXTERNAL_RNG) in config_adjust_mbedtls_from_psa_crypto.h.
  • Add test_hmac_drbg test component similar to test_no_ctr_drbg_use_psa in mbedtls.
  • Add test_hmac_drbg_aes_only_128_bit_keys test component similar to test_no_ctr_drbg_aes_only_128_bit_keys in mbedtls.
  • Add test_ctr_drbg_aes_256_sha_256, test_ctr_drbg_aes_128_sha_512 and test_ctr_drbg_aes_128_sha_256 similar to the mbedtls ones
  • Add test_psa_external_rng test component equivalent to test_rng_no_drbg_use_psa and test_psa_external_rng_use_psa_crypt
  • Check that the test components do what they intend to do and give evidence of this in this issue or the associated PR for the benefit of reviewers

Notes:

  • In psa-crypto the selection between CTR_DRBG and HMAC_DRBG is done through PSA_CRYPTO_HMAC_DRBG_HASH (see crypto_config.h)
  • No need for test_no_ctr_drbg_use_psa and test_no_hmac_drbg_use_psa equivalents as in psa-crypto there is no configuration option to enable or disable the CTR_DRBG and HMAC_DRBG modules.

Depends on:

@ronald-cron-arm ronald-cron-arm added enhancement New feature or request size-s Estimated task size: small (~2d) labels Sep 28, 2023
@github-project-automation github-project-automation bot moved this to PSA repo Q4 - all.sh components in Backlog for Mbed TLS Aug 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request size-s Estimated task size: small (~2d)
Projects
Status: PSA repo Q4 - all.sh components
Development

No branches or pull requests

1 participant