Merge pull request #7656 from mprse/ffdh_tls13_v2_drivers

FFDH 4: driver-only parity testing - with TLS 1.3
This commit is contained in:
Manuel Pégourié-Gonnard 2023-07-10 13:08:47 +02:00 committed by GitHub
commit f614bde912
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 34 additions and 4 deletions

View File

@ -2270,8 +2270,8 @@ component_test_psa_crypto_config_accel_ffdh () {
# Configure
# ---------
# Start from default config (no TLS 1.3, no USE_PSA)
helper_libtestdriver1_adjust_config "default"
# start with full (USE_PSA and TLS 1.3)
helper_libtestdriver1_adjust_config "full"
# Disable the module that's accelerated
scripts/config.py unset MBEDTLS_DHM_C
@ -2295,6 +2295,27 @@ component_test_psa_crypto_config_accel_ffdh () {
msg "test: MBEDTLS_PSA_CRYPTO_CONFIG with accelerated FFDH"
make test
msg "ssl-opt: MBEDTLS_PSA_CRYPTO_CONFIG with accelerated FFDH alg"
tests/ssl-opt.sh -f "ffdh"
}
component_test_psa_crypto_config_reference_ffdh () {
msg "build: MBEDTLS_PSA_CRYPTO_CONFIG with accelerated FFDH"
# Start with full (USE_PSA and TLS 1.3)
helper_libtestdriver1_adjust_config "full"
# Disable things that are not supported
scripts/config.py unset MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED
scripts/config.py unset MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED
make
msg "test suites: MBEDTLS_PSA_CRYPTO_CONFIG with non-accelerated FFDH alg + USE_PSA"
make test
msg "ssl-opt: MBEDTLS_PSA_CRYPTO_CONFIG with non-accelerated FFDH alg + USE_PSA"
tests/ssl-opt.sh -f "ffdh"
}
component_test_psa_crypto_config_accel_pake() {

View File

@ -262,7 +262,7 @@ TASKS = {
('Key ASN1 (OneAsymmetricKey X25519, doesn\'t match masking '
'requirements, from RFC8410 Appendix A but made into version 0)'),
],
}
},
}
},
'analyze_driver_vs_reference_no_ecp_at_all': {
@ -328,6 +328,15 @@ TASKS = {
}
}
},
'analyze_driver_vs_reference_ffdh_alg': {
'test_function': do_analyze_driver_vs_reference,
'args': {
'component_ref': 'test_psa_crypto_config_reference_ffdh',
'component_driver': 'test_psa_crypto_config_accel_ffdh',
'ignored_suites': ['dhm'],
'ignored_tests': {}
}
},
}
def main():

View File

@ -699,7 +699,7 @@ void ecc_key_family(int curve_arg)
}
/* END_CASE */
/* BEGIN_CASE depends_on:MBEDTLS_DHM_C */
/* BEGIN_CASE depends_on:PSA_KEY_TYPE_DH_PUBLIC_KEY:PSA_KEY_TYPE_DH_KEY_PAIR */
void dh_key_family(int group_arg)
{
psa_dh_family_t group = group_arg;