mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-01-30 06:33:06 +00:00
Move config-thread.h testing to separate all.sh components
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
This commit is contained in:
parent
b6d4913df9
commit
86ceb133d4
@ -196,6 +196,52 @@ component_test_tls1_2_default_cbc_legacy_cbc_etm_cipher_only () {
|
||||
tests/ssl-opt.sh -f "TLS 1.2"
|
||||
}
|
||||
|
||||
component_test_config_thread_legacy () {
|
||||
msg "build: configs/config-thread.h"
|
||||
cp configs/config-thread.h "$CONFIG_H"
|
||||
# test-ref-configs works by overwriting mbedtls_config.h; this makes cmake
|
||||
# want to re-generate generated files that depend on it, quite correctly.
|
||||
# However this doesn't work as the generation script expects a specific
|
||||
# format for mbedtls_config.h, which the other files don't follow. Also,
|
||||
# cmake can't know this, but re-generation is actually not necessary as
|
||||
# the generated files only depend on the list of available options, not
|
||||
# whether they're on or off. So, disable cmake's (over-sensitive here)
|
||||
# dependency resolution for generated files and just rely on them being
|
||||
# present (thanks to pre_generate_files) by turning GEN_FILES off.
|
||||
CC=$ASAN_CC cmake -D GEN_FILES=Off -D CMAKE_BUILD_TYPE:String=Asan .
|
||||
make
|
||||
|
||||
msg "test: configs/config-thread.h - unit tests"
|
||||
make test
|
||||
|
||||
msg "test: configs/config-thread.h - ssl-opt.sh"
|
||||
tests/ssl-opt.sh -f 'ECJPAKE.*nolog'
|
||||
}
|
||||
|
||||
component_test_config_thread_psa () {
|
||||
msg "build: configs/config-thread.h + USE_PSA_CRYPTO"
|
||||
cp configs/config-thread.h "$CONFIG_H"
|
||||
scripts/config.py set MBEDTLS_PSA_CRYPTO_C
|
||||
scripts/config.py set MBEDTLS_USE_PSA_CRYPTO
|
||||
# test-ref-configs works by overwriting mbedtls_config.h; this makes cmake
|
||||
# want to re-generate generated files that depend on it, quite correctly.
|
||||
# However this doesn't work as the generation script expects a specific
|
||||
# format for mbedtls_config.h, which the other files don't follow. Also,
|
||||
# cmake can't know this, but re-generation is actually not necessary as
|
||||
# the generated files only depend on the list of available options, not
|
||||
# whether they're on or off. So, disable cmake's (over-sensitive here)
|
||||
# dependency resolution for generated files and just rely on them being
|
||||
# present (thanks to pre_generate_files) by turning GEN_FILES off.
|
||||
CC=$ASAN_CC cmake -D GEN_FILES=Off -D CMAKE_BUILD_TYPE:String=Asan .
|
||||
make
|
||||
|
||||
msg "test: configs/config-thread.h + USE_PSA_CRYPTO - unit tests"
|
||||
make test
|
||||
|
||||
msg "test: configs/config-thread.h + USE_PSA_CRYPTO - ssl-opt.sh"
|
||||
tests/ssl-opt.sh -f 'ECJPAKE.*nolog'
|
||||
}
|
||||
|
||||
# We're not aware of any other (open source) implementation of EC J-PAKE in TLS
|
||||
# that we could use for interop testing. However, we now have sort of two
|
||||
# implementations ourselves: one using PSA, the other not. At least test that
|
||||
|
@ -20,9 +20,6 @@ my %configs = (
|
||||
},
|
||||
'config-tfm.h' => {
|
||||
},
|
||||
'config-thread.h' => {
|
||||
'opt' => '-f ECJPAKE.*nolog',
|
||||
},
|
||||
);
|
||||
|
||||
# If no config-name is provided, use all known configs.
|
||||
|
Loading…
x
Reference in New Issue
Block a user