library: check_config: remove RSA encryption requirement from ECDHE-RSA#10639
library: check_config: remove RSA encryption requirement from ECDHE-RSA#10639valeriosetti wants to merge 3 commits intoMbed-TLS:developmentfrom
Conversation
| #if defined(MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED) && \ | ||
| ( !defined(MBEDTLS_CAN_ECDH) || !defined(PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC) || \ | ||
| !defined(MBEDTLS_X509_CRT_PARSE_C) || !defined(PSA_WANT_ALG_RSA_PKCS1V15_CRYPT) || !defined(PSA_WANT_ALG_RSA_PKCS1V15_SIGN) ) | ||
| !defined(MBEDTLS_X509_CRT_PARSE_C) || !defined(PSA_WANT_ALG_RSA_PKCS1V15_SIGN) ) |
There was a problem hiding this comment.
Can we also update the dependency here tests/scripts/depends.py:277, or is this still required?
There was a problem hiding this comment.
Nice catch, thanks!
| 'MBEDTLS_X509_RSASSA_PSS_SUPPORT'], | ||
| 'PSA_WANT_ALG_RSA_PKCS1V15_CRYPT': ['PSA_WANT_ALG_RSA_PKCS1V15_SIGN', | ||
| 'MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED'], | ||
| 'PSA_WANT_ALG_RSA_PKCS1V15_CRYPT': ['PSA_WANT_ALG_RSA_PKCS1V15_SIGN'], |
There was a problem hiding this comment.
I can't see this dependency in either of the check_config.h files. I think what we need here is:
| 'PSA_WANT_ALG_RSA_PKCS1V15_CRYPT': ['PSA_WANT_ALG_RSA_PKCS1V15_SIGN'], | |
| 'PSA_WANT_ALG_RSA_PKCS1V15_SIGN': ['MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED'], |
(I haven't tested whether this would make the CI happy.)
There was a problem hiding this comment.
Oh yes, of course. Previously it was working because PSA_WANT_ALG_RSA_PKCS1V15_SIGN and MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED were disabled at the same time (from the wrong signal, but still...).
Thanks! I will apply immediately
|
Sorry, I had to patch |
ad15abb to
cea8af6
Compare
|
@yanesca @bjwtaylor since this PR missed the code freeze, please wait for the CI to be fully green before taking another look. |
|
I think that current CI complains in It seems we have no tests where |
d685e02 to
88ba826
Compare
ECDHE-RSA only requires RSA signature, not encryption. This commits fixes guards in "mbedtls_check_config.h". Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
…SIGN Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
0cba37d to
a201a74
Compare
| 'PSA_WANT_KEY_TYPE_ECC_KEY_PAIR_BASIC', | ||
| 'PSA_WANT_ALG_RSA_OAEP', | ||
| 'PSA_WANT_ALG_RSA_PKCS1V15_CRYPT', | ||
| 'PSA_WANT_ALG_RSA_PKCS1V15_SIGN', |
There was a problem hiding this comment.
@mpg does this somehow reduces gaps for RSA testing you mentioned recently?
There was a problem hiding this comment.
I don't think this line does, what I was after was builds with RSA_PUBLIC_KEY but not RSA_KEY_PAIR_BASIC. Though looking at the context, we seem to have that already - not sure why it didn't show when I searched the outcomes file, perhaps it's not being correctly filled by depends.py? That's something I'd like to double-check later. (Unless you beat me to it, of course - please feel free!)
|
@bjwtaylor @yanesca now the CI is fine. |
|
@yanesca can you please take another look at this PR? Question: since this is adding a new check in |
yanesca
left a comment
There was a problem hiding this comment.
LGTM.
Regarding the backport, I agree that we shouldn't fiddle with a user facing headers, but this one looks safe: We are removing a requirement, whatever config built successfully will continue to build in the future, this change shouldn't break any existing user.
Description
ECDHE-RSA only requires RSA signature, not encryption. This commits fixes guards in "mbedtls_check_config.h".
PR checklist
developmentwhere guards are PSA only