-
Notifications
You must be signed in to change notification settings - Fork 37
[framework] PK: try storing all private RSA keys in PSA (1/3) #171
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
Conversation
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
563a3b3
to
2b62f29
Compare
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
The previous key had only 518 bits for E. Being not a multiple of 8 this didn't allow the key to be imported into PSA. Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2b62f29
to
aa5018d
Compare
Only Windows failures left in the CI, but all of them are related to the CI, not to the code, so I'm going to remove the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, assuming that Mbed-TLS/TF-PSA-Crypto#308 does the right thing (I haven't reviewed it yet).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM with very minor/optional nit 🙂
case MBEDTLS_PK_RSA: | ||
#if defined(MBEDTLS_PK_USE_PSA_RSA_DATA) | ||
TEST_ASSERT(PSA_KEY_TYPE_IS_RSA(psa_type)); | ||
pk_public = pk->pub_raw; | ||
pk_public_length = pk->pub_raw_len; | ||
break; | ||
#else /* MBEDTLS_PK_USE_PSA_RSA_DATA */ | ||
TEST_ASSERT(PSA_KEY_TYPE_IS_RSA(psa_type)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor nit - could probably have moved the duplicated TEST_ASSERT
out of the #if defined
but only a minor code style thing.
Description
Helps resolving Mbed-TLS/TF-PSA-Crypto#298
This is PR 1 out of 3 for this series to solve that issue
Shadow PR with everything: Mbed-TLS/mbedtls#10228
PR checklist
development