mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-10-27 12:15:33 +03:00
Prepare test components to scripts/legacy.make
Signed-off-by: Ronald Cron <ronald.cron@arm.com>
This commit is contained in:
@@ -18,14 +18,14 @@ component_check_recursion () {
|
|||||||
|
|
||||||
component_check_generated_files () {
|
component_check_generated_files () {
|
||||||
msg "Check make_generated_files.py consistency"
|
msg "Check make_generated_files.py consistency"
|
||||||
make neat
|
$MAKE_COMMAND neat
|
||||||
$FRAMEWORK/scripts/make_generated_files.py
|
$FRAMEWORK/scripts/make_generated_files.py
|
||||||
$FRAMEWORK/scripts/make_generated_files.py --check
|
$FRAMEWORK/scripts/make_generated_files.py --check
|
||||||
make neat
|
$MAKE_COMMAND neat
|
||||||
|
|
||||||
msg "Check files generated with make"
|
msg "Check files generated with make"
|
||||||
MBEDTLS_ROOT_DIR="$PWD"
|
MBEDTLS_ROOT_DIR="$PWD"
|
||||||
make generated_files
|
$MAKE_COMMAND generated_files
|
||||||
$FRAMEWORK/scripts/make_generated_files.py --check
|
$FRAMEWORK/scripts/make_generated_files.py --check
|
||||||
|
|
||||||
cd $TF_PSA_CRYPTO_ROOT_DIR
|
cd $TF_PSA_CRYPTO_ROOT_DIR
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
|
|
||||||
component_test_make_shared () {
|
component_test_make_shared () {
|
||||||
msg "build/test: make shared" # ~ 40s
|
msg "build/test: make shared" # ~ 40s
|
||||||
make SHARED=1 TEST_CPP=1 all check
|
$MAKE_COMMAND SHARED=1 TEST_CPP=1 all check
|
||||||
ldd programs/util/strerror | grep libmbedcrypto
|
ldd programs/util/strerror | grep libmbedcrypto
|
||||||
$FRAMEWORK/tests/programs/dlopen_demo.sh
|
$FRAMEWORK/tests/programs/dlopen_demo.sh
|
||||||
}
|
}
|
||||||
@@ -58,7 +58,7 @@ support_test_cmake_out_of_source () {
|
|||||||
component_test_cmake_out_of_source () {
|
component_test_cmake_out_of_source () {
|
||||||
# Remove existing generated files so that we use the ones cmake
|
# Remove existing generated files so that we use the ones cmake
|
||||||
# generates
|
# generates
|
||||||
make neat
|
$MAKE_COMMAND neat
|
||||||
|
|
||||||
msg "build: cmake 'out-of-source' build"
|
msg "build: cmake 'out-of-source' build"
|
||||||
MBEDTLS_ROOT_DIR="$PWD"
|
MBEDTLS_ROOT_DIR="$PWD"
|
||||||
@@ -90,7 +90,7 @@ component_test_cmake_out_of_source () {
|
|||||||
component_test_cmake_as_subdirectory () {
|
component_test_cmake_as_subdirectory () {
|
||||||
# Remove existing generated files so that we use the ones CMake
|
# Remove existing generated files so that we use the ones CMake
|
||||||
# generates
|
# generates
|
||||||
make neat
|
$MAKE_COMMAND neat
|
||||||
|
|
||||||
msg "build: cmake 'as-subdirectory' build"
|
msg "build: cmake 'as-subdirectory' build"
|
||||||
cd programs/test/cmake_subproject
|
cd programs/test/cmake_subproject
|
||||||
@@ -107,7 +107,7 @@ support_test_cmake_as_subdirectory () {
|
|||||||
component_test_cmake_as_package () {
|
component_test_cmake_as_package () {
|
||||||
# Remove existing generated files so that we use the ones CMake
|
# Remove existing generated files so that we use the ones CMake
|
||||||
# generates
|
# generates
|
||||||
make neat
|
$MAKE_COMMAND neat
|
||||||
|
|
||||||
msg "build: cmake 'as-package' build"
|
msg "build: cmake 'as-package' build"
|
||||||
root_dir="$(pwd)"
|
root_dir="$(pwd)"
|
||||||
@@ -132,7 +132,7 @@ support_test_cmake_as_package () {
|
|||||||
component_test_cmake_as_package_install () {
|
component_test_cmake_as_package_install () {
|
||||||
# Remove existing generated files so that we use the ones CMake
|
# Remove existing generated files so that we use the ones CMake
|
||||||
# generates
|
# generates
|
||||||
make neat
|
$MAKE_COMMAND neat
|
||||||
|
|
||||||
msg "build: cmake 'as-installed-package' build"
|
msg "build: cmake 'as-installed-package' build"
|
||||||
cd programs/test/cmake_package_install
|
cd programs/test/cmake_package_install
|
||||||
|
|||||||
@@ -27,13 +27,13 @@ test_build_opt () {
|
|||||||
$cc --version
|
$cc --version
|
||||||
for opt in "$@"; do
|
for opt in "$@"; do
|
||||||
msg "build/test: $cc $opt, $info" # ~ 30s
|
msg "build/test: $cc $opt, $info" # ~ 30s
|
||||||
make CC="$cc" CFLAGS="$opt -std=c99 -pedantic -Wall -Wextra -Werror"
|
$MAKE_COMMAND CC="$cc" CFLAGS="$opt -std=c99 -pedantic -Wall -Wextra -Werror"
|
||||||
# We're confident enough in compilers to not run _all_ the tests,
|
# We're confident enough in compilers to not run _all_ the tests,
|
||||||
# but at least run the unit tests. In particular, runs with
|
# but at least run the unit tests. In particular, runs with
|
||||||
# optimizations use inline assembly whereas runs with -O0
|
# optimizations use inline assembly whereas runs with -O0
|
||||||
# skip inline assembly.
|
# skip inline assembly.
|
||||||
make test # ~30s
|
$MAKE_COMMAND test # ~30s
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -94,10 +94,10 @@ component_test_gcc15_drivers_opt () {
|
|||||||
loc_cflags="$ASAN_CFLAGS -DPSA_CRYPTO_DRIVER_TEST -DMBEDTLS_CONFIG_ADJUST_TEST_ACCELERATORS"
|
loc_cflags="$ASAN_CFLAGS -DPSA_CRYPTO_DRIVER_TEST -DMBEDTLS_CONFIG_ADJUST_TEST_ACCELERATORS"
|
||||||
loc_cflags="${loc_cflags} -I../framework/tests/include -O2"
|
loc_cflags="${loc_cflags} -I../framework/tests/include -O2"
|
||||||
|
|
||||||
make CC=$GCC_15 CFLAGS="${loc_cflags}" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=$GCC_15 CFLAGS="${loc_cflags}" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: GCC 15: full + test drivers dispatching to builtins"
|
msg "test: GCC 15: full + test drivers dispatching to builtins"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_gcc_earliest_opt () {
|
component_test_gcc_earliest_opt () {
|
||||||
@@ -111,21 +111,21 @@ support_test_gcc_earliest_opt () {
|
|||||||
|
|
||||||
component_build_mingw () {
|
component_build_mingw () {
|
||||||
msg "build: Windows cross build - mingw64, make (Link Library)" # ~ 30s
|
msg "build: Windows cross build - mingw64, make (Link Library)" # ~ 30s
|
||||||
make CC=i686-w64-mingw32-gcc AR=i686-w64-mingw32-ar CFLAGS='-Werror -Wall -Wextra -maes -msse2 -mpclmul' WINDOWS_BUILD=1 lib programs
|
$MAKE_COMMAND CC=i686-w64-mingw32-gcc AR=i686-w64-mingw32-ar CFLAGS='-Werror -Wall -Wextra -maes -msse2 -mpclmul' WINDOWS_BUILD=1 lib programs
|
||||||
|
|
||||||
# note Make tests only builds the tests, but doesn't run them
|
# note Make tests only builds the tests, but doesn't run them
|
||||||
make CC=i686-w64-mingw32-gcc AR=i686-w64-mingw32-ar CFLAGS='-Werror -maes -msse2 -mpclmul' WINDOWS_BUILD=1 tests
|
$MAKE_COMMAND CC=i686-w64-mingw32-gcc AR=i686-w64-mingw32-ar CFLAGS='-Werror -maes -msse2 -mpclmul' WINDOWS_BUILD=1 tests
|
||||||
make WINDOWS_BUILD=1 clean
|
$MAKE_COMMAND WINDOWS_BUILD=1 clean
|
||||||
|
|
||||||
msg "build: Windows cross build - mingw64, make (DLL)" # ~ 30s
|
msg "build: Windows cross build - mingw64, make (DLL)" # ~ 30s
|
||||||
make CC=i686-w64-mingw32-gcc AR=i686-w64-mingw32-ar CFLAGS='-Werror -Wall -Wextra -maes -msse2 -mpclmul' WINDOWS_BUILD=1 SHARED=1 lib programs
|
$MAKE_COMMAND CC=i686-w64-mingw32-gcc AR=i686-w64-mingw32-ar CFLAGS='-Werror -Wall -Wextra -maes -msse2 -mpclmul' WINDOWS_BUILD=1 SHARED=1 lib programs
|
||||||
make CC=i686-w64-mingw32-gcc AR=i686-w64-mingw32-ar CFLAGS='-Werror -Wall -Wextra -maes -msse2 -mpclmul' WINDOWS_BUILD=1 SHARED=1 tests
|
$MAKE_COMMAND CC=i686-w64-mingw32-gcc AR=i686-w64-mingw32-ar CFLAGS='-Werror -Wall -Wextra -maes -msse2 -mpclmul' WINDOWS_BUILD=1 SHARED=1 tests
|
||||||
make WINDOWS_BUILD=1 clean
|
$MAKE_COMMAND WINDOWS_BUILD=1 clean
|
||||||
|
|
||||||
msg "build: Windows cross build - mingw64, make (Library only, default config without MBEDTLS_AESNI_C)" # ~ 30s
|
msg "build: Windows cross build - mingw64, make (Library only, default config without MBEDTLS_AESNI_C)" # ~ 30s
|
||||||
./scripts/config.py unset MBEDTLS_AESNI_C #
|
./scripts/config.py unset MBEDTLS_AESNI_C #
|
||||||
make CC=i686-w64-mingw32-gcc AR=i686-w64-mingw32-ar CFLAGS='-Werror -Wall -Wextra' WINDOWS_BUILD=1 lib
|
$MAKE_COMMAND CC=i686-w64-mingw32-gcc AR=i686-w64-mingw32-ar CFLAGS='-Werror -Wall -Wextra' WINDOWS_BUILD=1 lib
|
||||||
make WINDOWS_BUILD=1 clean
|
$MAKE_COMMAND WINDOWS_BUILD=1 clean
|
||||||
}
|
}
|
||||||
|
|
||||||
support_build_mingw () {
|
support_build_mingw () {
|
||||||
@@ -141,7 +141,7 @@ component_build_zeroize_checks () {
|
|||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
|
|
||||||
# Only compile - we're looking for sizeof-pointer-memaccess warnings
|
# Only compile - we're looking for sizeof-pointer-memaccess warnings
|
||||||
make CFLAGS="'-DTF_PSA_CRYPTO_USER_CONFIG_FILE=\"$TF_PSA_CRYPTO_ROOT_DIR/tests/configs/user-config-zeroize-memset.h\"' -DMBEDTLS_TEST_DEFINES_ZEROIZE -Werror -Wsizeof-pointer-memaccess"
|
$MAKE_COMMAND CFLAGS="'-DTF_PSA_CRYPTO_USER_CONFIG_FILE=\"$TF_PSA_CRYPTO_ROOT_DIR/tests/configs/user-config-zeroize-memset.h\"' -DMBEDTLS_TEST_DEFINES_ZEROIZE -Werror -Wsizeof-pointer-memaccess"
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_zeroize () {
|
component_test_zeroize () {
|
||||||
@@ -162,12 +162,12 @@ component_test_zeroize () {
|
|||||||
for optimization_flag in -O2 -O3 -Ofast -Os; do
|
for optimization_flag in -O2 -O3 -Ofast -Os; do
|
||||||
for compiler in clang gcc; do
|
for compiler in clang gcc; do
|
||||||
msg "test: $compiler $optimization_flag, mbedtls_platform_zeroize()"
|
msg "test: $compiler $optimization_flag, mbedtls_platform_zeroize()"
|
||||||
make programs CC="$compiler" DEBUG=1 CFLAGS="$optimization_flag"
|
$MAKE_COMMAND programs CC="$compiler" DEBUG=1 CFLAGS="$optimization_flag"
|
||||||
gdb -ex "$gdb_disable_aslr" -x $FRAMEWORK/tests/programs/test_zeroize.gdb -nw -batch -nx 2>&1 | tee test_zeroize.log
|
gdb -ex "$gdb_disable_aslr" -x $FRAMEWORK/tests/programs/test_zeroize.gdb -nw -batch -nx 2>&1 | tee test_zeroize.log
|
||||||
grep "The buffer was correctly zeroized" test_zeroize.log
|
grep "The buffer was correctly zeroized" test_zeroize.log
|
||||||
not grep -i "error" test_zeroize.log
|
not grep -i "error" test_zeroize.log
|
||||||
rm -f test_zeroize.log
|
rm -f test_zeroize.log
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ component_test_crypto_with_static_key_slots() {
|
|||||||
scripts/config.py unset MBEDTLS_PSA_KEY_STORE_DYNAMIC
|
scripts/config.py unset MBEDTLS_PSA_KEY_STORE_DYNAMIC
|
||||||
|
|
||||||
msg "test: crypto full + MBEDTLS_PSA_STATIC_KEY_SLOTS"
|
msg "test: crypto full + MBEDTLS_PSA_STATIC_KEY_SLOTS"
|
||||||
make CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS" test
|
$MAKE_COMMAND CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS" test
|
||||||
}
|
}
|
||||||
|
|
||||||
# check_renamed_symbols HEADER LIB
|
# check_renamed_symbols HEADER LIB
|
||||||
@@ -67,7 +67,7 @@ component_build_psa_crypto_spm () {
|
|||||||
# We can only compile, not link, since our test and sample programs
|
# We can only compile, not link, since our test and sample programs
|
||||||
# aren't equipped for the modified names used when MBEDTLS_PSA_CRYPTO_SPM
|
# aren't equipped for the modified names used when MBEDTLS_PSA_CRYPTO_SPM
|
||||||
# is active.
|
# is active.
|
||||||
make CC=gcc CFLAGS='-Werror -Wall -Wextra -I../framework/tests/include/spe' lib
|
$MAKE_COMMAND CC=gcc CFLAGS='-Werror -Wall -Wextra -I../framework/tests/include/spe' lib
|
||||||
|
|
||||||
# Check that if a symbol is renamed by crypto_spe.h, the non-renamed
|
# Check that if a symbol is renamed by crypto_spe.h, the non-renamed
|
||||||
# version is not present.
|
# version is not present.
|
||||||
@@ -138,16 +138,16 @@ component_test_psa_crypto_without_heap() {
|
|||||||
helper_libtestdriver1_make_main "$loc_accel_list" tests
|
helper_libtestdriver1_make_main "$loc_accel_list" tests
|
||||||
|
|
||||||
msg "crypto without heap: test"
|
msg "crypto without heap: test"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_no_rsa_key_pair_generation () {
|
component_test_no_rsa_key_pair_generation () {
|
||||||
msg "build: default config minus PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_GENERATE"
|
msg "build: default config minus PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_GENERATE"
|
||||||
scripts/config.py unset PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_GENERATE
|
scripts/config.py unset PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_GENERATE
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test: default config minus PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_GENERATE"
|
msg "test: default config minus PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_GENERATE"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_no_pem_no_fs () {
|
component_test_no_pem_no_fs () {
|
||||||
@@ -241,10 +241,10 @@ component_test_psa_external_rng_no_drbg_use_psa () {
|
|||||||
scripts/config.py unset MBEDTLS_CTR_DRBG_C
|
scripts/config.py unset MBEDTLS_CTR_DRBG_C
|
||||||
scripts/config.py unset MBEDTLS_HMAC_DRBG_C
|
scripts/config.py unset MBEDTLS_HMAC_DRBG_C
|
||||||
scripts/config.py unset PSA_WANT_ALG_DETERMINISTIC_ECDSA # Requires HMAC_DRBG
|
scripts/config.py unset PSA_WANT_ALG_DETERMINISTIC_ECDSA # Requires HMAC_DRBG
|
||||||
make CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: PSA_CRYPTO_EXTERNAL_RNG minus *_DRBG, PSA crypto - main suites"
|
msg "test: PSA_CRYPTO_EXTERNAL_RNG minus *_DRBG, PSA crypto - main suites"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "test: PSA_CRYPTO_EXTERNAL_RNG minus *_DRBG, PSA crypto - ssl-opt.sh (subset)"
|
msg "test: PSA_CRYPTO_EXTERNAL_RNG minus *_DRBG, PSA crypto - ssl-opt.sh (subset)"
|
||||||
tests/ssl-opt.sh -f 'Default\|opaque'
|
tests/ssl-opt.sh -f 'Default\|opaque'
|
||||||
@@ -257,10 +257,10 @@ component_test_psa_external_rng_use_psa_crypto () {
|
|||||||
scripts/config.py unset MBEDTLS_CTR_DRBG_C
|
scripts/config.py unset MBEDTLS_CTR_DRBG_C
|
||||||
scripts/config.py unset MBEDTLS_ENTROPY_NV_SEED
|
scripts/config.py unset MBEDTLS_ENTROPY_NV_SEED
|
||||||
scripts/config.py unset MBEDTLS_PLATFORM_NV_SEED_ALT
|
scripts/config.py unset MBEDTLS_PLATFORM_NV_SEED_ALT
|
||||||
make CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: full + PSA_CRYPTO_EXTERNAL_RNG + USE_PSA_CRYPTO minus CTR_DRBG/NV_SEED"
|
msg "test: full + PSA_CRYPTO_EXTERNAL_RNG + USE_PSA_CRYPTO minus CTR_DRBG/NV_SEED"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "test: full + PSA_CRYPTO_EXTERNAL_RNG + USE_PSA_CRYPTO minus CTR_DRBG/NV_SEED"
|
msg "test: full + PSA_CRYPTO_EXTERNAL_RNG + USE_PSA_CRYPTO minus CTR_DRBG/NV_SEED"
|
||||||
tests/ssl-opt.sh -f 'Default\|opaque'
|
tests/ssl-opt.sh -f 'Default\|opaque'
|
||||||
@@ -273,14 +273,14 @@ component_full_no_pkparse_pkwrite () {
|
|||||||
scripts/config.py unset MBEDTLS_PK_PARSE_C
|
scripts/config.py unset MBEDTLS_PK_PARSE_C
|
||||||
scripts/config.py unset MBEDTLS_PK_WRITE_C
|
scripts/config.py unset MBEDTLS_PK_WRITE_C
|
||||||
|
|
||||||
make CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
# Ensure that PK_[PARSE|WRITE]_C were not re-enabled accidentally (additive config).
|
# Ensure that PK_[PARSE|WRITE]_C were not re-enabled accidentally (additive config).
|
||||||
not grep mbedtls_pk_parse_key ${BUILTIN_SRC_PATH}/pkparse.o
|
not grep mbedtls_pk_parse_key ${BUILTIN_SRC_PATH}/pkparse.o
|
||||||
not grep mbedtls_pk_write_key_der ${BUILTIN_SRC_PATH}/pkwrite.o
|
not grep mbedtls_pk_write_key_der ${BUILTIN_SRC_PATH}/pkwrite.o
|
||||||
|
|
||||||
msg "test: full without pkparse and pkwrite"
|
msg "test: full without pkparse and pkwrite"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_crypto_full_md_light_only () {
|
component_test_crypto_full_md_light_only () {
|
||||||
@@ -300,14 +300,14 @@ component_test_crypto_full_md_light_only () {
|
|||||||
|
|
||||||
# Note: MD-light is auto-enabled in build_info.h by modules that need it,
|
# Note: MD-light is auto-enabled in build_info.h by modules that need it,
|
||||||
# which we haven't disabled, so no need to explicitly enable it.
|
# which we haven't disabled, so no need to explicitly enable it.
|
||||||
make CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
# Make sure we don't have the HMAC functions, but the hashing functions
|
# Make sure we don't have the HMAC functions, but the hashing functions
|
||||||
not grep mbedtls_md_hmac ${BUILTIN_SRC_PATH}/md.o
|
not grep mbedtls_md_hmac ${BUILTIN_SRC_PATH}/md.o
|
||||||
grep mbedtls_md ${BUILTIN_SRC_PATH}/md.o
|
grep mbedtls_md ${BUILTIN_SRC_PATH}/md.o
|
||||||
|
|
||||||
msg "test: crypto_full with only the light subset of MD"
|
msg "test: crypto_full with only the light subset of MD"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_full_no_cipher () {
|
component_test_full_no_cipher () {
|
||||||
@@ -334,13 +334,13 @@ component_test_full_no_cipher () {
|
|||||||
# The following modules directly depends on CIPHER_C
|
# The following modules directly depends on CIPHER_C
|
||||||
scripts/config.py unset MBEDTLS_NIST_KW_C
|
scripts/config.py unset MBEDTLS_NIST_KW_C
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
# Ensure that CIPHER_C was not re-enabled
|
# Ensure that CIPHER_C was not re-enabled
|
||||||
not grep mbedtls_cipher_init ${BUILTIN_SRC_PATH}/cipher.o
|
not grep mbedtls_cipher_init ${BUILTIN_SRC_PATH}/cipher.o
|
||||||
|
|
||||||
msg "test: full no CIPHER"
|
msg "test: full no CIPHER"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_full_no_ccm () {
|
component_test_full_no_ccm () {
|
||||||
@@ -359,10 +359,10 @@ component_test_full_no_ccm () {
|
|||||||
# PSA_WANT_ALG_CCM to be re-enabled.
|
# PSA_WANT_ALG_CCM to be re-enabled.
|
||||||
scripts/config.py unset PSA_WANT_ALG_CCM
|
scripts/config.py unset PSA_WANT_ALG_CCM
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test: full no PSA_WANT_ALG_CCM"
|
msg "test: full no PSA_WANT_ALG_CCM"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_full_no_ccm_star_no_tag () {
|
component_test_full_no_ccm_star_no_tag () {
|
||||||
@@ -390,13 +390,13 @@ component_test_full_no_ccm_star_no_tag () {
|
|||||||
scripts/config.py unset PSA_WANT_ALG_CBC_NO_PADDING
|
scripts/config.py unset PSA_WANT_ALG_CBC_NO_PADDING
|
||||||
scripts/config.py unset PSA_WANT_ALG_CBC_PKCS7
|
scripts/config.py unset PSA_WANT_ALG_CBC_PKCS7
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
# Ensure MBEDTLS_PSA_BUILTIN_CIPHER was not enabled
|
# Ensure MBEDTLS_PSA_BUILTIN_CIPHER was not enabled
|
||||||
not grep mbedtls_psa_cipher ${PSA_CORE_PATH}/psa_crypto_cipher.o
|
not grep mbedtls_psa_cipher ${PSA_CORE_PATH}/psa_crypto_cipher.o
|
||||||
|
|
||||||
msg "test: full no PSA_WANT_ALG_CCM_STAR_NO_TAG"
|
msg "test: full no PSA_WANT_ALG_CCM_STAR_NO_TAG"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_config_symmetric_only () {
|
component_test_config_symmetric_only () {
|
||||||
@@ -444,10 +444,10 @@ component_test_everest_curve25519_only () {
|
|||||||
scripts/config.py unset-all "PSA_WANT_ECC_[0-9A-Z_a-z]*$"
|
scripts/config.py unset-all "PSA_WANT_ECC_[0-9A-Z_a-z]*$"
|
||||||
scripts/config.py set PSA_WANT_ECC_MONTGOMERY_255
|
scripts/config.py set PSA_WANT_ECC_MONTGOMERY_255
|
||||||
|
|
||||||
make CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: Everest ECDH context, only Curve25519" # ~ 50s
|
msg "test: Everest ECDH context, only Curve25519" # ~ 50s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_psa_collect_statuses () {
|
component_test_psa_collect_statuses () {
|
||||||
@@ -491,14 +491,14 @@ component_test_crypto_for_psa_service () {
|
|||||||
scripts/config.py unset MBEDTLS_PK_C
|
scripts/config.py unset MBEDTLS_PK_C
|
||||||
scripts/config.py unset MBEDTLS_PK_PARSE_C
|
scripts/config.py unset MBEDTLS_PK_PARSE_C
|
||||||
scripts/config.py unset MBEDTLS_PK_WRITE_C
|
scripts/config.py unset MBEDTLS_PK_WRITE_C
|
||||||
make CFLAGS='-O1 -Werror' all test
|
$MAKE_COMMAND CFLAGS='-O1 -Werror' all test
|
||||||
are_empty_libraries library/libmbedx509.* library/libmbedtls.*
|
are_empty_libraries library/libmbedx509.* library/libmbedtls.*
|
||||||
}
|
}
|
||||||
|
|
||||||
component_build_crypto_baremetal () {
|
component_build_crypto_baremetal () {
|
||||||
msg "build: make, crypto only, baremetal config"
|
msg "build: make, crypto only, baremetal config"
|
||||||
scripts/config.py crypto_baremetal
|
scripts/config.py crypto_baremetal
|
||||||
make CFLAGS="-O1 -Werror -I$PWD/framework/tests/include/baremetal-override/"
|
$MAKE_COMMAND CFLAGS="-O1 -Werror -I$PWD/framework/tests/include/baremetal-override/"
|
||||||
are_empty_libraries library/libmbedx509.* library/libmbedtls.*
|
are_empty_libraries library/libmbedx509.* library/libmbedtls.*
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -543,10 +543,10 @@ component_test_psa_crypto_config_ffdh_2048_only () {
|
|||||||
scripts/config.py unset PSA_WANT_DH_RFC7919_6144
|
scripts/config.py unset PSA_WANT_DH_RFC7919_6144
|
||||||
scripts/config.py unset PSA_WANT_DH_RFC7919_8192
|
scripts/config.py unset PSA_WANT_DH_RFC7919_8192
|
||||||
|
|
||||||
make CFLAGS="$ASAN_CFLAGS -Werror" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CFLAGS="$ASAN_CFLAGS -Werror" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: full config - only DH 2048"
|
msg "test: full config - only DH 2048"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "ssl-opt: full config - only DH 2048"
|
msg "ssl-opt: full config - only DH 2048"
|
||||||
tests/ssl-opt.sh -f "ffdh"
|
tests/ssl-opt.sh -f "ffdh"
|
||||||
@@ -587,7 +587,7 @@ component_test_psa_crypto_config_accel_ecdsa () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: accelerated ECDSA"
|
msg "test: accelerated ECDSA"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_psa_crypto_config_accel_ecdh () {
|
component_test_psa_crypto_config_accel_ecdh () {
|
||||||
@@ -623,7 +623,7 @@ component_test_psa_crypto_config_accel_ecdh () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: accelerated ECDH"
|
msg "test: accelerated ECDH"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_psa_crypto_config_accel_ffdh () {
|
component_test_psa_crypto_config_accel_ffdh () {
|
||||||
@@ -654,7 +654,7 @@ component_test_psa_crypto_config_accel_ffdh () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: full with accelerated FFDH"
|
msg "test: full with accelerated FFDH"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "ssl-opt: full with accelerated FFDH alg"
|
msg "ssl-opt: full with accelerated FFDH alg"
|
||||||
tests/ssl-opt.sh -f "ffdh"
|
tests/ssl-opt.sh -f "ffdh"
|
||||||
@@ -666,10 +666,10 @@ component_test_psa_crypto_config_reference_ffdh () {
|
|||||||
# Start with full (USE_PSA and TLS 1.3)
|
# Start with full (USE_PSA and TLS 1.3)
|
||||||
helper_libtestdriver1_adjust_config "full"
|
helper_libtestdriver1_adjust_config "full"
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test suites: full with non-accelerated FFDH alg"
|
msg "test suites: full with non-accelerated FFDH alg"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "ssl-opt: full with non-accelerated FFDH alg"
|
msg "ssl-opt: full with non-accelerated FFDH alg"
|
||||||
tests/ssl-opt.sh -f "ffdh"
|
tests/ssl-opt.sh -f "ffdh"
|
||||||
@@ -704,7 +704,7 @@ component_test_psa_crypto_config_accel_pake () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: full with accelerated PAKE"
|
msg "test: full with accelerated PAKE"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_psa_crypto_config_accel_ecc_some_key_types () {
|
component_test_psa_crypto_config_accel_ecc_some_key_types () {
|
||||||
@@ -758,7 +758,7 @@ component_test_psa_crypto_config_accel_ecc_some_key_types () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test suites: full with accelerated EC algs and some key types"
|
msg "test suites: full with accelerated EC algs and some key types"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
# Run tests with only (non-)Weierstrass accelerated
|
# Run tests with only (non-)Weierstrass accelerated
|
||||||
@@ -864,7 +864,7 @@ common_test_psa_crypto_config_accel_ecc_some_curves () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test suites: crypto_full minus PK with accelerated EC algs and $desc curves"
|
msg "test suites: crypto_full minus PK with accelerated EC algs and $desc curves"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_psa_crypto_config_accel_ecc_weierstrass_curves () {
|
component_test_psa_crypto_config_accel_ecc_weierstrass_curves () {
|
||||||
@@ -938,7 +938,7 @@ component_test_psa_crypto_config_accel_ecc_ecp_light_only () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test suites: full with accelerated EC algs"
|
msg "test suites: full with accelerated EC algs"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "ssl-opt: full with accelerated EC algs"
|
msg "ssl-opt: full with accelerated EC algs"
|
||||||
tests/ssl-opt.sh
|
tests/ssl-opt.sh
|
||||||
@@ -950,10 +950,10 @@ component_test_psa_crypto_config_reference_ecc_ecp_light_only () {
|
|||||||
|
|
||||||
config_psa_crypto_config_ecp_light_only 0
|
config_psa_crypto_config_ecp_light_only 0
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test suites: full with non-accelerated EC algs"
|
msg "test suites: full with non-accelerated EC algs"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "ssl-opt: full with non-accelerated EC algs"
|
msg "ssl-opt: full with non-accelerated EC algs"
|
||||||
tests/ssl-opt.sh
|
tests/ssl-opt.sh
|
||||||
@@ -1034,7 +1034,7 @@ component_test_psa_crypto_config_accel_ecc_no_ecp_at_all () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: full + accelerated EC algs - ECP"
|
msg "test: full + accelerated EC algs - ECP"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "ssl-opt: full + accelerated EC algs - ECP"
|
msg "ssl-opt: full + accelerated EC algs - ECP"
|
||||||
tests/ssl-opt.sh
|
tests/ssl-opt.sh
|
||||||
@@ -1048,10 +1048,10 @@ component_test_psa_crypto_config_reference_ecc_no_ecp_at_all () {
|
|||||||
|
|
||||||
config_psa_crypto_no_ecp_at_all 0
|
config_psa_crypto_no_ecp_at_all 0
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test: full + non accelerated EC algs"
|
msg "test: full + non accelerated EC algs"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "ssl-opt: full + non accelerated EC algs"
|
msg "ssl-opt: full + non accelerated EC algs"
|
||||||
tests/ssl-opt.sh
|
tests/ssl-opt.sh
|
||||||
@@ -1183,7 +1183,7 @@ common_test_psa_crypto_config_accel_ecc_ffdh_no_bignum () {
|
|||||||
|
|
||||||
msg "test suites: full + accelerated $accel_text algs + USE_PSA - $removed_text - BIGNUM"
|
msg "test suites: full + accelerated $accel_text algs + USE_PSA - $removed_text - BIGNUM"
|
||||||
|
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "ssl-opt: full + accelerated $accel_text algs + USE_PSA - $removed_text - BIGNUM"
|
msg "ssl-opt: full + accelerated $accel_text algs + USE_PSA - $removed_text - BIGNUM"
|
||||||
tests/ssl-opt.sh
|
tests/ssl-opt.sh
|
||||||
@@ -1214,10 +1214,10 @@ common_test_psa_crypto_config_reference_ecc_ffdh_no_bignum () {
|
|||||||
|
|
||||||
config_psa_crypto_config_accel_ecc_ffdh_no_bignum 0 "$test_target"
|
config_psa_crypto_config_accel_ecc_ffdh_no_bignum 0 "$test_target"
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test suites: full + non accelerated EC algs + USE_PSA"
|
msg "test suites: full + non accelerated EC algs + USE_PSA"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "ssl-opt: full + non accelerated $accel_text algs + USE_PSA"
|
msg "ssl-opt: full + non accelerated $accel_text algs + USE_PSA"
|
||||||
tests/ssl-opt.sh
|
tests/ssl-opt.sh
|
||||||
@@ -1273,7 +1273,7 @@ component_test_tfm_config_p256m_driver_accel_ec () {
|
|||||||
common_tfm_config
|
common_tfm_config
|
||||||
|
|
||||||
# Build crypto library
|
# Build crypto library
|
||||||
make CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS -I../framework/tests/include/spe" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS -I../framework/tests/include/spe" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
# Make sure any built-in EC alg was not re-enabled by accident (additive config)
|
# Make sure any built-in EC alg was not re-enabled by accident (additive config)
|
||||||
not grep mbedtls_ecdsa_ ${BUILTIN_SRC_PATH}/ecdsa.o
|
not grep mbedtls_ecdsa_ ${BUILTIN_SRC_PATH}/ecdsa.o
|
||||||
@@ -1292,7 +1292,7 @@ component_test_tfm_config_p256m_driver_accel_ec () {
|
|||||||
|
|
||||||
# Run the tests
|
# Run the tests
|
||||||
msg "test: TF-M config + p256m driver + accel ECDH(E)/ECDSA"
|
msg "test: TF-M config + p256m driver + accel ECDH(E)/ECDSA"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
# Keep this in sync with component_test_tfm_config_p256m_driver_accel_ec() as
|
# Keep this in sync with component_test_tfm_config_p256m_driver_accel_ec() as
|
||||||
@@ -1306,7 +1306,7 @@ component_test_tfm_config_no_p256m () {
|
|||||||
scripts/config.py -f "$CRYPTO_CONFIG_H" unset MBEDTLS_PSA_P256M_DRIVER_ENABLED
|
scripts/config.py -f "$CRYPTO_CONFIG_H" unset MBEDTLS_PSA_P256M_DRIVER_ENABLED
|
||||||
|
|
||||||
msg "build: TF-M config without p256m"
|
msg "build: TF-M config without p256m"
|
||||||
make CFLAGS='-Werror -Wall -Wextra -I../framework/tests/include/spe' tests
|
$MAKE_COMMAND CFLAGS='-Werror -Wall -Wextra -I../framework/tests/include/spe' tests
|
||||||
|
|
||||||
# Check that p256m was not built
|
# Check that p256m was not built
|
||||||
not grep p256_ecdsa_ library/libmbedcrypto.a
|
not grep p256_ecdsa_ library/libmbedcrypto.a
|
||||||
@@ -1316,7 +1316,7 @@ component_test_tfm_config_no_p256m () {
|
|||||||
not grep mbedtls_cipher ${BUILTIN_SRC_PATH}/cipher.o
|
not grep mbedtls_cipher ${BUILTIN_SRC_PATH}/cipher.o
|
||||||
|
|
||||||
msg "test: TF-M config without p256m"
|
msg "test: TF-M config without p256m"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
# This is an helper used by:
|
# This is an helper used by:
|
||||||
@@ -1340,10 +1340,10 @@ build_and_test_psa_want_key_pair_partial () {
|
|||||||
# crypto_config.h so we just disable the one we don't want.
|
# crypto_config.h so we just disable the one we don't want.
|
||||||
scripts/config.py unset "$disabled_psa_want"
|
scripts/config.py unset "$disabled_psa_want"
|
||||||
|
|
||||||
make CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: $base_config - ${disabled_psa_want}"
|
msg "test: $base_config - ${disabled_psa_want}"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_psa_ecc_key_pair_no_derive () {
|
component_test_psa_ecc_key_pair_no_derive () {
|
||||||
@@ -1405,7 +1405,7 @@ component_test_psa_crypto_config_accel_rsa_crypto () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: crypto_full with accelerated RSA"
|
msg "test: crypto_full with accelerated RSA"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_psa_crypto_config_reference_rsa_crypto () {
|
component_test_psa_crypto_config_reference_rsa_crypto () {
|
||||||
@@ -1417,12 +1417,12 @@ component_test_psa_crypto_config_reference_rsa_crypto () {
|
|||||||
|
|
||||||
# Build
|
# Build
|
||||||
# -----
|
# -----
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
# Run the tests
|
# Run the tests
|
||||||
# -------------
|
# -------------
|
||||||
msg "test: crypto_full with non-accelerated RSA"
|
msg "test: crypto_full with non-accelerated RSA"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
# This is a temporary test to verify that full RSA support is present even when
|
# This is a temporary test to verify that full RSA support is present even when
|
||||||
@@ -1452,10 +1452,10 @@ component_test_new_psa_want_key_pair_symbol () {
|
|||||||
scripts/config.py unset PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_EXPORT
|
scripts/config.py unset PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_EXPORT
|
||||||
scripts/config.py unset PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_GENERATE
|
scripts/config.py unset PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_GENERATE
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "Test: crypto config - PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC"
|
msg "Test: crypto config - PSA_WANT_KEY_TYPE_RSA_KEY_PAIR_BASIC"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
# Parse only 1 relevant line from the outcome file, i.e. a test which is
|
# Parse only 1 relevant line from the outcome file, i.e. a test which is
|
||||||
# performing RSA signature.
|
# performing RSA signature.
|
||||||
@@ -1499,7 +1499,7 @@ component_test_psa_crypto_config_accel_hash () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: accelerated hash"
|
msg "test: accelerated hash"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
# Auxiliary function to build config for hashes with and without drivers
|
# Auxiliary function to build config for hashes with and without drivers
|
||||||
@@ -1548,7 +1548,7 @@ component_test_psa_crypto_config_accel_hash_use_psa () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: full with accelerated hashes"
|
msg "test: full with accelerated hashes"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
# This is mostly useful so that we can later compare outcome files with
|
# This is mostly useful so that we can later compare outcome files with
|
||||||
# the reference config in analyze_outcomes.py, to check that the
|
# the reference config in analyze_outcomes.py, to check that the
|
||||||
@@ -1571,10 +1571,10 @@ component_test_psa_crypto_config_reference_hash_use_psa () {
|
|||||||
|
|
||||||
config_psa_crypto_hash_use_psa 0
|
config_psa_crypto_hash_use_psa 0
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test: full without accelerated hashes"
|
msg "test: full without accelerated hashes"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "test: ssl-opt.sh, full without accelerated hashes"
|
msg "test: ssl-opt.sh, full without accelerated hashes"
|
||||||
tests/ssl-opt.sh
|
tests/ssl-opt.sh
|
||||||
@@ -1632,7 +1632,7 @@ component_test_psa_crypto_config_accel_hmac () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: full with accelerated hmac"
|
msg "test: full with accelerated hmac"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_psa_crypto_config_reference_hmac () {
|
component_test_psa_crypto_config_reference_hmac () {
|
||||||
@@ -1640,10 +1640,10 @@ component_test_psa_crypto_config_reference_hmac () {
|
|||||||
|
|
||||||
config_psa_crypto_hmac_use_psa 0
|
config_psa_crypto_hmac_use_psa 0
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test: full without accelerated hmac"
|
msg "test: full without accelerated hmac"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_psa_crypto_config_accel_aead () {
|
component_test_psa_crypto_config_accel_aead () {
|
||||||
@@ -1677,7 +1677,7 @@ component_test_psa_crypto_config_accel_aead () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: accelerated AEAD"
|
msg "test: accelerated AEAD"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
# This is a common configuration function used in:
|
# This is a common configuration function used in:
|
||||||
@@ -1734,7 +1734,7 @@ component_test_psa_crypto_config_accel_cipher_aead_cmac () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: full config with accelerated cipher inc. AEAD and CMAC"
|
msg "test: full config with accelerated cipher inc. AEAD and CMAC"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "ssl-opt: full config with accelerated cipher inc. AEAD and CMAC"
|
msg "ssl-opt: full config with accelerated cipher inc. AEAD and CMAC"
|
||||||
# Exclude password-protected key tests — they require built-in CBC and AES.
|
# Exclude password-protected key tests — they require built-in CBC and AES.
|
||||||
@@ -1752,10 +1752,10 @@ component_test_psa_crypto_config_reference_cipher_aead_cmac () {
|
|||||||
# This can be removed once we remove DES from the library.
|
# This can be removed once we remove DES from the library.
|
||||||
scripts/config.py unset PSA_WANT_KEY_TYPE_DES
|
scripts/config.py unset PSA_WANT_KEY_TYPE_DES
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test: full config with non-accelerated cipher inc. AEAD and CMAC"
|
msg "test: full config with non-accelerated cipher inc. AEAD and CMAC"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "ssl-opt: full config with non-accelerated cipher inc. AEAD and CMAC"
|
msg "ssl-opt: full config with non-accelerated cipher inc. AEAD and CMAC"
|
||||||
# Exclude password-protected key tests as in test_psa_crypto_config_accel_cipher_aead_cmac.
|
# Exclude password-protected key tests as in test_psa_crypto_config_accel_cipher_aead_cmac.
|
||||||
@@ -1826,7 +1826,7 @@ component_test_full_block_cipher_psa_dispatch_static_keystore () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: full + PSA dispatch in block_cipher with static keystore"
|
msg "test: full + PSA dispatch in block_cipher with static keystore"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_full_block_cipher_psa_dispatch () {
|
component_test_full_block_cipher_psa_dispatch () {
|
||||||
@@ -1857,7 +1857,7 @@ component_test_full_block_cipher_psa_dispatch () {
|
|||||||
# -------------
|
# -------------
|
||||||
|
|
||||||
msg "test: full + PSA dispatch in block_cipher"
|
msg "test: full + PSA dispatch in block_cipher"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
# This is the reference component of component_test_full_block_cipher_psa_dispatch
|
# This is the reference component of component_test_full_block_cipher_psa_dispatch
|
||||||
@@ -1866,20 +1866,20 @@ component_test_full_block_cipher_legacy_dispatch () {
|
|||||||
|
|
||||||
common_block_cipher_dispatch 0
|
common_block_cipher_dispatch 0
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test: full + legacy dispatch in block_cipher"
|
msg "test: full + legacy dispatch in block_cipher"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_aead_chachapoly_disabled () {
|
component_test_aead_chachapoly_disabled () {
|
||||||
msg "build: full minus CHACHAPOLY"
|
msg "build: full minus CHACHAPOLY"
|
||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
scripts/config.py unset PSA_WANT_ALG_CHACHA20_POLY1305
|
scripts/config.py unset PSA_WANT_ALG_CHACHA20_POLY1305
|
||||||
make CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: full minus CHACHAPOLY"
|
msg "test: full minus CHACHAPOLY"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_aead_only_ccm () {
|
component_test_aead_only_ccm () {
|
||||||
@@ -1887,10 +1887,10 @@ component_test_aead_only_ccm () {
|
|||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
scripts/config.py unset PSA_WANT_ALG_CHACHA20_POLY1305
|
scripts/config.py unset PSA_WANT_ALG_CHACHA20_POLY1305
|
||||||
scripts/config.py unset PSA_WANT_ALG_GCM
|
scripts/config.py unset PSA_WANT_ALG_GCM
|
||||||
make CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=$ASAN_CC CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: full minus CHACHAPOLY and GCM"
|
msg "test: full minus CHACHAPOLY and GCM"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_ccm_aes_sha256 () {
|
component_test_ccm_aes_sha256 () {
|
||||||
@@ -1900,9 +1900,9 @@ component_test_ccm_aes_sha256 () {
|
|||||||
echo '#define MBEDTLS_CONFIG_H ' >"$CONFIG_H"
|
echo '#define MBEDTLS_CONFIG_H ' >"$CONFIG_H"
|
||||||
cp tf-psa-crypto/configs/crypto-config-ccm-aes-sha256.h "$CRYPTO_CONFIG_H"
|
cp tf-psa-crypto/configs/crypto-config-ccm-aes-sha256.h "$CRYPTO_CONFIG_H"
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
msg "test: CCM + AES + SHA256 configuration"
|
msg "test: CCM + AES + SHA256 configuration"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
# Test that the given .o file builds with all (valid) combinations of the given options.
|
# Test that the given .o file builds with all (valid) combinations of the given options.
|
||||||
@@ -2044,12 +2044,12 @@ END
|
|||||||
END
|
END
|
||||||
|
|
||||||
msg "all loops unrolled"
|
msg "all loops unrolled"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make -C tests ../tf-psa-crypto/tests/test_suite_shax CFLAGS="-DMBEDTLS_SHA3_THETA_UNROLL=1 -DMBEDTLS_SHA3_PI_UNROLL=1 -DMBEDTLS_SHA3_CHI_UNROLL=1 -DMBEDTLS_SHA3_RHO_UNROLL=1"
|
make -C tests ../tf-psa-crypto/tests/test_suite_shax CFLAGS="-DMBEDTLS_SHA3_THETA_UNROLL=1 -DMBEDTLS_SHA3_PI_UNROLL=1 -DMBEDTLS_SHA3_CHI_UNROLL=1 -DMBEDTLS_SHA3_RHO_UNROLL=1"
|
||||||
./tf-psa-crypto/tests/test_suite_shax
|
./tf-psa-crypto/tests/test_suite_shax
|
||||||
|
|
||||||
msg "all loops rolled up"
|
msg "all loops rolled up"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make -C tests ../tf-psa-crypto/tests/test_suite_shax CFLAGS="-DMBEDTLS_SHA3_THETA_UNROLL=0 -DMBEDTLS_SHA3_PI_UNROLL=0 -DMBEDTLS_SHA3_CHI_UNROLL=0 -DMBEDTLS_SHA3_RHO_UNROLL=0"
|
make -C tests ../tf-psa-crypto/tests/test_suite_shax CFLAGS="-DMBEDTLS_SHA3_THETA_UNROLL=0 -DMBEDTLS_SHA3_PI_UNROLL=0 -DMBEDTLS_SHA3_CHI_UNROLL=0 -DMBEDTLS_SHA3_RHO_UNROLL=0"
|
||||||
./tf-psa-crypto/tests/test_suite_shax
|
./tf-psa-crypto/tests/test_suite_shax
|
||||||
}
|
}
|
||||||
@@ -2091,10 +2091,10 @@ component_test_aes_only_128_bit_keys () {
|
|||||||
scripts/config.py set MBEDTLS_AES_ONLY_128_BIT_KEY_LENGTH
|
scripts/config.py set MBEDTLS_AES_ONLY_128_BIT_KEY_LENGTH
|
||||||
scripts/config.py set MBEDTLS_PSA_CRYPTO_RNG_STRENGTH 128
|
scripts/config.py set MBEDTLS_PSA_CRYPTO_RNG_STRENGTH 128
|
||||||
|
|
||||||
make CFLAGS='-O2 -Werror -Wall -Wextra'
|
$MAKE_COMMAND CFLAGS='-O2 -Werror -Wall -Wextra'
|
||||||
|
|
||||||
msg "test: default config + AES_ONLY_128_BIT_KEY_LENGTH"
|
msg "test: default config + AES_ONLY_128_BIT_KEY_LENGTH"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_no_ctr_drbg_aes_only_128_bit_keys () {
|
component_test_no_ctr_drbg_aes_only_128_bit_keys () {
|
||||||
@@ -2103,10 +2103,10 @@ component_test_no_ctr_drbg_aes_only_128_bit_keys () {
|
|||||||
scripts/config.py set MBEDTLS_PSA_CRYPTO_RNG_STRENGTH 128
|
scripts/config.py set MBEDTLS_PSA_CRYPTO_RNG_STRENGTH 128
|
||||||
scripts/config.py unset MBEDTLS_CTR_DRBG_C
|
scripts/config.py unset MBEDTLS_CTR_DRBG_C
|
||||||
|
|
||||||
make CC=clang CFLAGS='-Werror -Wall -Wextra'
|
$MAKE_COMMAND CC=clang CFLAGS='-Werror -Wall -Wextra'
|
||||||
|
|
||||||
msg "test: default config + AES_ONLY_128_BIT_KEY_LENGTH - CTR_DRBG_C"
|
msg "test: default config + AES_ONLY_128_BIT_KEY_LENGTH - CTR_DRBG_C"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_aes_only_128_bit_keys_have_builtins () {
|
component_test_aes_only_128_bit_keys_have_builtins () {
|
||||||
@@ -2116,10 +2116,10 @@ component_test_aes_only_128_bit_keys_have_builtins () {
|
|||||||
scripts/config.py unset MBEDTLS_AESNI_C
|
scripts/config.py unset MBEDTLS_AESNI_C
|
||||||
scripts/config.py unset MBEDTLS_AESCE_C
|
scripts/config.py unset MBEDTLS_AESCE_C
|
||||||
|
|
||||||
make CFLAGS='-O2 -Werror -Wall -Wextra'
|
$MAKE_COMMAND CFLAGS='-O2 -Werror -Wall -Wextra'
|
||||||
|
|
||||||
msg "test: default config + AES_ONLY_128_BIT_KEY_LENGTH - AESNI_C - AESCE_C"
|
msg "test: default config + AES_ONLY_128_BIT_KEY_LENGTH - AESNI_C - AESCE_C"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "selftest: default config + AES_ONLY_128_BIT_KEY_LENGTH - AESNI_C - AESCE_C"
|
msg "selftest: default config + AES_ONLY_128_BIT_KEY_LENGTH - AESNI_C - AESCE_C"
|
||||||
programs/test/selftest
|
programs/test/selftest
|
||||||
@@ -2131,38 +2131,38 @@ component_test_gcm_largetable () {
|
|||||||
scripts/config.py unset MBEDTLS_AESNI_C
|
scripts/config.py unset MBEDTLS_AESNI_C
|
||||||
scripts/config.py unset MBEDTLS_AESCE_C
|
scripts/config.py unset MBEDTLS_AESCE_C
|
||||||
|
|
||||||
make CFLAGS='-O2 -Werror -Wall -Wextra'
|
$MAKE_COMMAND CFLAGS='-O2 -Werror -Wall -Wextra'
|
||||||
|
|
||||||
msg "test: default config - GCM_LARGE_TABLE - AESNI_C - AESCE_C"
|
msg "test: default config - GCM_LARGE_TABLE - AESNI_C - AESCE_C"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_aes_fewer_tables () {
|
component_test_aes_fewer_tables () {
|
||||||
msg "build: default config with AES_FEWER_TABLES enabled"
|
msg "build: default config with AES_FEWER_TABLES enabled"
|
||||||
scripts/config.py set MBEDTLS_AES_FEWER_TABLES
|
scripts/config.py set MBEDTLS_AES_FEWER_TABLES
|
||||||
make CFLAGS='-O2 -Werror -Wall -Wextra'
|
$MAKE_COMMAND CFLAGS='-O2 -Werror -Wall -Wextra'
|
||||||
|
|
||||||
msg "test: AES_FEWER_TABLES"
|
msg "test: AES_FEWER_TABLES"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_aes_rom_tables () {
|
component_test_aes_rom_tables () {
|
||||||
msg "build: default config with AES_ROM_TABLES enabled"
|
msg "build: default config with AES_ROM_TABLES enabled"
|
||||||
scripts/config.py set MBEDTLS_AES_ROM_TABLES
|
scripts/config.py set MBEDTLS_AES_ROM_TABLES
|
||||||
make CFLAGS='-O2 -Werror -Wall -Wextra'
|
$MAKE_COMMAND CFLAGS='-O2 -Werror -Wall -Wextra'
|
||||||
|
|
||||||
msg "test: AES_ROM_TABLES"
|
msg "test: AES_ROM_TABLES"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_aes_fewer_tables_and_rom_tables () {
|
component_test_aes_fewer_tables_and_rom_tables () {
|
||||||
msg "build: default config with AES_ROM_TABLES and AES_FEWER_TABLES enabled"
|
msg "build: default config with AES_ROM_TABLES and AES_FEWER_TABLES enabled"
|
||||||
scripts/config.py set MBEDTLS_AES_FEWER_TABLES
|
scripts/config.py set MBEDTLS_AES_FEWER_TABLES
|
||||||
scripts/config.py set MBEDTLS_AES_ROM_TABLES
|
scripts/config.py set MBEDTLS_AES_ROM_TABLES
|
||||||
make CFLAGS='-O2 -Werror -Wall -Wextra'
|
$MAKE_COMMAND CFLAGS='-O2 -Werror -Wall -Wextra'
|
||||||
|
|
||||||
msg "test: AES_FEWER_TABLES + AES_ROM_TABLES"
|
msg "test: AES_FEWER_TABLES + AES_ROM_TABLES"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
# helper for component_test_block_cipher_no_decrypt_aesni() which:
|
# helper for component_test_block_cipher_no_decrypt_aesni() which:
|
||||||
@@ -2200,8 +2200,8 @@ helper_block_cipher_no_decrypt_build_test () {
|
|||||||
[ -n "$unset_opts" ] && echo "Disabling: $unset_opts" && scripts/config.py unset-all $unset_opts
|
[ -n "$unset_opts" ] && echo "Disabling: $unset_opts" && scripts/config.py unset-all $unset_opts
|
||||||
|
|
||||||
msg "build: default config + BLOCK_CIPHER_NO_DECRYPT${set_opts:+ + $set_opts}${unset_opts:+ - $unset_opts} with $cflags${ldflags:+, $ldflags}"
|
msg "build: default config + BLOCK_CIPHER_NO_DECRYPT${set_opts:+ + $set_opts}${unset_opts:+ - $unset_opts} with $cflags${ldflags:+, $ldflags}"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make CFLAGS="-O2 $cflags" LDFLAGS="$ldflags"
|
$MAKE_COMMAND CFLAGS="-O2 $cflags" LDFLAGS="$ldflags"
|
||||||
|
|
||||||
# Make sure we don't have mbedtls_xxx_setkey_dec in AES/ARIA/CAMELLIA
|
# Make sure we don't have mbedtls_xxx_setkey_dec in AES/ARIA/CAMELLIA
|
||||||
not grep mbedtls_aes_setkey_dec ${BUILTIN_SRC_PATH}/aes.o
|
not grep mbedtls_aes_setkey_dec ${BUILTIN_SRC_PATH}/aes.o
|
||||||
@@ -2213,7 +2213,7 @@ helper_block_cipher_no_decrypt_build_test () {
|
|||||||
not grep mbedtls_aesni_inverse_key ${BUILTIN_SRC_PATH}/aesni.o
|
not grep mbedtls_aesni_inverse_key ${BUILTIN_SRC_PATH}/aesni.o
|
||||||
|
|
||||||
msg "test: default config + BLOCK_CIPHER_NO_DECRYPT${set_opts:+ + $set_opts}${unset_opts:+ - $unset_opts} with $cflags${ldflags:+, $ldflags}"
|
msg "test: default config + BLOCK_CIPHER_NO_DECRYPT${set_opts:+ + $set_opts}${unset_opts:+ - $unset_opts} with $cflags${ldflags:+, $ldflags}"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "selftest: default config + BLOCK_CIPHER_NO_DECRYPT${set_opts:+ + $set_opts}${unset_opts:+ - $unset_opts} with $cflags${ldflags:+, $ldflags}"
|
msg "selftest: default config + BLOCK_CIPHER_NO_DECRYPT${set_opts:+ + $set_opts}${unset_opts:+ - $unset_opts} with $cflags${ldflags:+, $ldflags}"
|
||||||
programs/test/selftest
|
programs/test/selftest
|
||||||
@@ -2352,10 +2352,10 @@ component_test_full_static_keystore () {
|
|||||||
msg "build: full config - MBEDTLS_PSA_KEY_STORE_DYNAMIC"
|
msg "build: full config - MBEDTLS_PSA_KEY_STORE_DYNAMIC"
|
||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
scripts/config.py unset MBEDTLS_PSA_KEY_STORE_DYNAMIC
|
scripts/config.py unset MBEDTLS_PSA_KEY_STORE_DYNAMIC
|
||||||
make CC=clang CFLAGS="$ASAN_CFLAGS -Os" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=clang CFLAGS="$ASAN_CFLAGS -Os" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: full config - MBEDTLS_PSA_KEY_STORE_DYNAMIC"
|
msg "test: full config - MBEDTLS_PSA_KEY_STORE_DYNAMIC"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_psa_crypto_drivers () {
|
component_test_psa_crypto_drivers () {
|
||||||
@@ -2373,20 +2373,20 @@ component_test_psa_crypto_drivers () {
|
|||||||
loc_cflags="$ASAN_CFLAGS -DPSA_CRYPTO_DRIVER_TEST -DMBEDTLS_CONFIG_ADJUST_TEST_ACCELERATORS"
|
loc_cflags="$ASAN_CFLAGS -DPSA_CRYPTO_DRIVER_TEST -DMBEDTLS_CONFIG_ADJUST_TEST_ACCELERATORS"
|
||||||
loc_cflags="${loc_cflags} -I../framework/tests/include"
|
loc_cflags="${loc_cflags} -I../framework/tests/include"
|
||||||
|
|
||||||
make CC=$ASAN_CC CFLAGS="${loc_cflags}" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=$ASAN_CC CFLAGS="${loc_cflags}" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: full + test drivers dispatching to builtins"
|
msg "test: full + test drivers dispatching to builtins"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_build_psa_config_file () {
|
component_build_psa_config_file () {
|
||||||
msg "build: make with TF_PSA_CRYPTO_CONFIG_FILE" # ~40s
|
msg "build: make with TF_PSA_CRYPTO_CONFIG_FILE" # ~40s
|
||||||
cp "$CRYPTO_CONFIG_H" psa_test_config.h
|
cp "$CRYPTO_CONFIG_H" psa_test_config.h
|
||||||
echo '#error "TF_PSA_CRYPTO_CONFIG_FILE is not working"' >"$CRYPTO_CONFIG_H"
|
echo '#error "TF_PSA_CRYPTO_CONFIG_FILE is not working"' >"$CRYPTO_CONFIG_H"
|
||||||
make CFLAGS="-I '$PWD' -DTF_PSA_CRYPTO_CONFIG_FILE='\"psa_test_config.h\"'"
|
$MAKE_COMMAND CFLAGS="-I '$PWD' -DTF_PSA_CRYPTO_CONFIG_FILE='\"psa_test_config.h\"'"
|
||||||
# Make sure this feature is enabled. We'll disable it in the next phase.
|
# Make sure this feature is enabled. We'll disable it in the next phase.
|
||||||
programs/test/query_compile_time_config PSA_WANT_ALG_CMAC
|
programs/test/query_compile_time_config PSA_WANT_ALG_CMAC
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
|
|
||||||
msg "build: make with TF_PSA_CRYPTO_CONFIG_FILE + TF_PSA_CRYPTO_USER_CONFIG_FILE" # ~40s
|
msg "build: make with TF_PSA_CRYPTO_CONFIG_FILE + TF_PSA_CRYPTO_USER_CONFIG_FILE" # ~40s
|
||||||
# In the user config, disable one feature and its dependencies, which will
|
# In the user config, disable one feature and its dependencies, which will
|
||||||
@@ -2394,7 +2394,7 @@ component_build_psa_config_file () {
|
|||||||
# query_compile_time_config.
|
# query_compile_time_config.
|
||||||
echo '#undef PSA_WANT_ALG_CMAC' >psa_user_config.h
|
echo '#undef PSA_WANT_ALG_CMAC' >psa_user_config.h
|
||||||
echo '#undef PSA_WANT_ALG_PBKDF2_AES_CMAC_PRF_128' >> psa_user_config.h
|
echo '#undef PSA_WANT_ALG_PBKDF2_AES_CMAC_PRF_128' >> psa_user_config.h
|
||||||
make CFLAGS="-I '$PWD' -DTF_PSA_CRYPTO_CONFIG_FILE='\"psa_test_config.h\"' -DTF_PSA_CRYPTO_USER_CONFIG_FILE='\"psa_user_config.h\"'"
|
$MAKE_COMMAND CFLAGS="-I '$PWD' -DTF_PSA_CRYPTO_CONFIG_FILE='\"psa_test_config.h\"' -DTF_PSA_CRYPTO_USER_CONFIG_FILE='\"psa_user_config.h\"'"
|
||||||
not programs/test/query_compile_time_config PSA_WANT_ALG_CMAC
|
not programs/test/query_compile_time_config PSA_WANT_ALG_CMAC
|
||||||
|
|
||||||
rm -f psa_test_config.h psa_user_config.h
|
rm -f psa_test_config.h psa_user_config.h
|
||||||
@@ -2410,7 +2410,7 @@ component_build_psa_alt_headers () {
|
|||||||
# Build the library and some programs.
|
# Build the library and some programs.
|
||||||
# Don't build the fuzzers to avoid having to go through hoops to set
|
# Don't build the fuzzers to avoid having to go through hoops to set
|
||||||
# a correct include path for programs/fuzz/Makefile.
|
# a correct include path for programs/fuzz/Makefile.
|
||||||
make CFLAGS="-I ../framework/tests/include/alt-extra -DMBEDTLS_PSA_CRYPTO_PLATFORM_FILE='\"psa/crypto_platform_alt.h\"' -DMBEDTLS_PSA_CRYPTO_STRUCT_FILE='\"psa/crypto_struct_alt.h\"'" lib
|
$MAKE_COMMAND CFLAGS="-I ../framework/tests/include/alt-extra -DMBEDTLS_PSA_CRYPTO_PLATFORM_FILE='\"psa/crypto_platform_alt.h\"' -DMBEDTLS_PSA_CRYPTO_STRUCT_FILE='\"psa/crypto_struct_alt.h\"'" lib
|
||||||
make -C programs -o fuzz CFLAGS="-I ../framework/tests/include/alt-extra -DMBEDTLS_PSA_CRYPTO_PLATFORM_FILE='\"psa/crypto_platform_alt.h\"' -DMBEDTLS_PSA_CRYPTO_STRUCT_FILE='\"psa/crypto_struct_alt.h\"'"
|
make -C programs -o fuzz CFLAGS="-I ../framework/tests/include/alt-extra -DMBEDTLS_PSA_CRYPTO_PLATFORM_FILE='\"psa/crypto_platform_alt.h\"' -DMBEDTLS_PSA_CRYPTO_STRUCT_FILE='\"psa/crypto_struct_alt.h\"'"
|
||||||
|
|
||||||
# Check that we're getting the alternative include guards and not the
|
# Check that we're getting the alternative include guards and not the
|
||||||
|
|||||||
@@ -28,11 +28,11 @@ component_test_psa_driver_get_entropy()
|
|||||||
scripts/config.py unset MBEDTLS_ENTROPY_NV_SEED
|
scripts/config.py unset MBEDTLS_ENTROPY_NV_SEED
|
||||||
scripts/config.py set MBEDTLS_PSA_DRIVER_GET_ENTROPY
|
scripts/config.py set MBEDTLS_PSA_DRIVER_GET_ENTROPY
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
# Run all the tests
|
# Run all the tests
|
||||||
msg "test: default - MBEDTLS_PSA_BUILTIN_GET_ENTROPY + MBEDTLS_PSA_DRIVER_GET_ENTROPY"
|
msg "test: default - MBEDTLS_PSA_BUILTIN_GET_ENTROPY + MBEDTLS_PSA_DRIVER_GET_ENTROPY"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_build_no_sockets () {
|
component_build_no_sockets () {
|
||||||
@@ -43,7 +43,7 @@ component_build_no_sockets () {
|
|||||||
scripts/config.py unset MBEDTLS_NET_C # getaddrinfo() undeclared, etc.
|
scripts/config.py unset MBEDTLS_NET_C # getaddrinfo() undeclared, etc.
|
||||||
scripts/config.py unset MBEDTLS_PSA_BUILTIN_GET_ENTROPY # prevent syscall() on GNU/Linux
|
scripts/config.py unset MBEDTLS_PSA_BUILTIN_GET_ENTROPY # prevent syscall() on GNU/Linux
|
||||||
scripts/config.py set MBEDTLS_PSA_DRIVER_GET_ENTROPY
|
scripts/config.py set MBEDTLS_PSA_DRIVER_GET_ENTROPY
|
||||||
make CC=gcc CFLAGS='-Werror -Wall -Wextra -O1 -std=c99 -pedantic' lib
|
$MAKE_COMMAND CC=gcc CFLAGS='-Werror -Wall -Wextra -O1 -std=c99 -pedantic' lib
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_no_date_time () {
|
component_test_no_date_time () {
|
||||||
@@ -73,10 +73,10 @@ component_test_have_int32 () {
|
|||||||
scripts/config.py unset MBEDTLS_HAVE_ASM
|
scripts/config.py unset MBEDTLS_HAVE_ASM
|
||||||
scripts/config.py unset MBEDTLS_AESNI_C
|
scripts/config.py unset MBEDTLS_AESNI_C
|
||||||
scripts/config.py unset MBEDTLS_AESCE_C
|
scripts/config.py unset MBEDTLS_AESCE_C
|
||||||
make CC=gcc CFLAGS='-O2 -Werror -Wall -Wextra -DMBEDTLS_HAVE_INT32'
|
$MAKE_COMMAND CC=gcc CFLAGS='-O2 -Werror -Wall -Wextra -DMBEDTLS_HAVE_INT32'
|
||||||
|
|
||||||
msg "test: gcc, force 32-bit bignum limbs"
|
msg "test: gcc, force 32-bit bignum limbs"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_have_int64 () {
|
component_test_have_int64 () {
|
||||||
@@ -84,10 +84,10 @@ component_test_have_int64 () {
|
|||||||
scripts/config.py unset MBEDTLS_HAVE_ASM
|
scripts/config.py unset MBEDTLS_HAVE_ASM
|
||||||
scripts/config.py unset MBEDTLS_AESNI_C
|
scripts/config.py unset MBEDTLS_AESNI_C
|
||||||
scripts/config.py unset MBEDTLS_AESCE_C
|
scripts/config.py unset MBEDTLS_AESCE_C
|
||||||
make CC=gcc CFLAGS='-O2 -Werror -Wall -Wextra -DMBEDTLS_HAVE_INT64'
|
$MAKE_COMMAND CC=gcc CFLAGS='-O2 -Werror -Wall -Wextra -DMBEDTLS_HAVE_INT64'
|
||||||
|
|
||||||
msg "test: gcc, force 64-bit bignum limbs"
|
msg "test: gcc, force 64-bit bignum limbs"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_have_int32_cmake_new_bignum () {
|
component_test_have_int32_cmake_new_bignum () {
|
||||||
@@ -97,28 +97,28 @@ component_test_have_int32_cmake_new_bignum () {
|
|||||||
scripts/config.py unset MBEDTLS_AESCE_C
|
scripts/config.py unset MBEDTLS_AESCE_C
|
||||||
scripts/config.py set MBEDTLS_TEST_HOOKS
|
scripts/config.py set MBEDTLS_TEST_HOOKS
|
||||||
scripts/config.py set MBEDTLS_ECP_WITH_MPI_UINT
|
scripts/config.py set MBEDTLS_ECP_WITH_MPI_UINT
|
||||||
make CC=gcc CFLAGS="$ASAN_CFLAGS -Werror -Wall -Wextra -DMBEDTLS_HAVE_INT32" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=gcc CFLAGS="$ASAN_CFLAGS -Werror -Wall -Wextra -DMBEDTLS_HAVE_INT32" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: gcc, force 32-bit bignum limbs, new bignum interface, test hooks (ASan build)"
|
msg "test: gcc, force 32-bit bignum limbs, new bignum interface, test hooks (ASan build)"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_no_udbl_division () {
|
component_test_no_udbl_division () {
|
||||||
msg "build: MBEDTLS_NO_UDBL_DIVISION native" # ~ 10s
|
msg "build: MBEDTLS_NO_UDBL_DIVISION native" # ~ 10s
|
||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
scripts/config.py set MBEDTLS_NO_UDBL_DIVISION
|
scripts/config.py set MBEDTLS_NO_UDBL_DIVISION
|
||||||
make CFLAGS='-Werror -O1'
|
$MAKE_COMMAND CFLAGS='-Werror -O1'
|
||||||
|
|
||||||
msg "test: MBEDTLS_NO_UDBL_DIVISION native" # ~ 10s
|
msg "test: MBEDTLS_NO_UDBL_DIVISION native" # ~ 10s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_no_64bit_multiplication () {
|
component_test_no_64bit_multiplication () {
|
||||||
msg "build: MBEDTLS_NO_64BIT_MULTIPLICATION native" # ~ 10s
|
msg "build: MBEDTLS_NO_64BIT_MULTIPLICATION native" # ~ 10s
|
||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
scripts/config.py set MBEDTLS_NO_64BIT_MULTIPLICATION
|
scripts/config.py set MBEDTLS_NO_64BIT_MULTIPLICATION
|
||||||
make CFLAGS='-Werror -O1'
|
$MAKE_COMMAND CFLAGS='-Werror -O1'
|
||||||
|
|
||||||
msg "test: MBEDTLS_NO_64BIT_MULTIPLICATION native" # ~ 10s
|
msg "test: MBEDTLS_NO_64BIT_MULTIPLICATION native" # ~ 10s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -67,10 +67,10 @@ component_test_tls1_2_default_stream_cipher_only () {
|
|||||||
scripts/config.py unset MBEDTLS_SSL_CONTEXT_SERIALIZATION
|
scripts/config.py unset MBEDTLS_SSL_CONTEXT_SERIALIZATION
|
||||||
scripts/config.py unset MBEDTLS_SSL_TICKET_C
|
scripts/config.py unset MBEDTLS_SSL_TICKET_C
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test: default with only stream cipher use psa"
|
msg "test: default with only stream cipher use psa"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
# Not running ssl-opt.sh because most tests require a non-NULL ciphersuite.
|
# Not running ssl-opt.sh because most tests require a non-NULL ciphersuite.
|
||||||
}
|
}
|
||||||
@@ -95,10 +95,10 @@ component_test_tls1_2_default_cbc_legacy_cipher_only () {
|
|||||||
scripts/config.py unset MBEDTLS_SSL_CONTEXT_SERIALIZATION
|
scripts/config.py unset MBEDTLS_SSL_CONTEXT_SERIALIZATION
|
||||||
scripts/config.py unset MBEDTLS_SSL_TICKET_C
|
scripts/config.py unset MBEDTLS_SSL_TICKET_C
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test: default with only CBC-legacy cipher use psa"
|
msg "test: default with only CBC-legacy cipher use psa"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "test: default with only CBC-legacy cipher use psa - ssl-opt.sh (subset)"
|
msg "test: default with only CBC-legacy cipher use psa - ssl-opt.sh (subset)"
|
||||||
tests/ssl-opt.sh -f "TLS 1.2"
|
tests/ssl-opt.sh -f "TLS 1.2"
|
||||||
@@ -124,10 +124,10 @@ component_test_tls1_2_default_cbc_legacy_cbc_etm_cipher_only () {
|
|||||||
scripts/config.py unset MBEDTLS_SSL_CONTEXT_SERIALIZATION
|
scripts/config.py unset MBEDTLS_SSL_CONTEXT_SERIALIZATION
|
||||||
scripts/config.py unset MBEDTLS_SSL_TICKET_C
|
scripts/config.py unset MBEDTLS_SSL_TICKET_C
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test: default with only CBC-legacy and CBC-EtM ciphers use psa"
|
msg "test: default with only CBC-legacy and CBC-EtM ciphers use psa"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "test: default with only CBC-legacy and CBC-EtM ciphers use psa - ssl-opt.sh (subset)"
|
msg "test: default with only CBC-legacy and CBC-EtM ciphers use psa - ssl-opt.sh (subset)"
|
||||||
tests/ssl-opt.sh -f "TLS 1.2"
|
tests/ssl-opt.sh -f "TLS 1.2"
|
||||||
@@ -245,7 +245,7 @@ build_full_minus_something_and_test_tls () {
|
|||||||
scripts/config.py unset $sym
|
scripts/config.py unset $sym
|
||||||
done
|
done
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test: full minus something, test TLS"
|
msg "test: full minus something, test TLS"
|
||||||
( cd tests; ./test_suite_ssl )
|
( cd tests; ./test_suite_ssl )
|
||||||
@@ -272,14 +272,14 @@ component_build_no_ssl_srv () {
|
|||||||
msg "build: full config except SSL server, make, gcc" # ~ 30s
|
msg "build: full config except SSL server, make, gcc" # ~ 30s
|
||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
scripts/config.py unset MBEDTLS_SSL_SRV_C
|
scripts/config.py unset MBEDTLS_SSL_SRV_C
|
||||||
make CC=gcc CFLAGS='-Werror -Wall -Wextra -O1 -Wmissing-prototypes'
|
$MAKE_COMMAND CC=gcc CFLAGS='-Werror -Wall -Wextra -O1 -Wmissing-prototypes'
|
||||||
}
|
}
|
||||||
|
|
||||||
component_build_no_ssl_cli () {
|
component_build_no_ssl_cli () {
|
||||||
msg "build: full config except SSL client, make, gcc" # ~ 30s
|
msg "build: full config except SSL client, make, gcc" # ~ 30s
|
||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
scripts/config.py unset MBEDTLS_SSL_CLI_C
|
scripts/config.py unset MBEDTLS_SSL_CLI_C
|
||||||
make CC=gcc CFLAGS='-Werror -Wall -Wextra -O1 -Wmissing-prototypes'
|
$MAKE_COMMAND CC=gcc CFLAGS='-Werror -Wall -Wextra -O1 -Wmissing-prototypes'
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_no_max_fragment_length () {
|
component_test_no_max_fragment_length () {
|
||||||
@@ -370,10 +370,10 @@ component_test_when_no_ciphersuites_have_mac () {
|
|||||||
|
|
||||||
scripts/config.py unset MBEDTLS_SSL_NULL_CIPHERSUITES
|
scripts/config.py unset MBEDTLS_SSL_NULL_CIPHERSUITES
|
||||||
|
|
||||||
make
|
$MAKE_COMMAND
|
||||||
|
|
||||||
msg "test: !MBEDTLS_SSL_SOME_SUITES_USE_MAC"
|
msg "test: !MBEDTLS_SSL_SOME_SUITES_USE_MAC"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "test ssl-opt.sh: !MBEDTLS_SSL_SOME_SUITES_USE_MAC"
|
msg "test ssl-opt.sh: !MBEDTLS_SSL_SOME_SUITES_USE_MAC"
|
||||||
tests/ssl-opt.sh -f 'Default\|EtM' -e 'without EtM'
|
tests/ssl-opt.sh -f 'Default\|EtM' -e 'without EtM'
|
||||||
@@ -401,10 +401,10 @@ component_test_tls13_only () {
|
|||||||
scripts/config.py set MBEDTLS_SSL_RECORD_SIZE_LIMIT
|
scripts/config.py set MBEDTLS_SSL_RECORD_SIZE_LIMIT
|
||||||
|
|
||||||
scripts/config.py set MBEDTLS_TEST_HOOKS
|
scripts/config.py set MBEDTLS_TEST_HOOKS
|
||||||
make CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
$MAKE_COMMAND CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
||||||
|
|
||||||
msg "test: TLS 1.3 only, all key exchange modes enabled"
|
msg "test: TLS 1.3 only, all key exchange modes enabled"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "ssl-opt.sh: TLS 1.3 only, all key exchange modes enabled"
|
msg "ssl-opt.sh: TLS 1.3 only, all key exchange modes enabled"
|
||||||
tests/ssl-opt.sh
|
tests/ssl-opt.sh
|
||||||
@@ -438,7 +438,7 @@ component_test_tls13_only_psk () {
|
|||||||
scripts/config.py unset PSA_WANT_DH_RFC7919_6144
|
scripts/config.py unset PSA_WANT_DH_RFC7919_6144
|
||||||
scripts/config.py unset PSA_WANT_DH_RFC7919_8192
|
scripts/config.py unset PSA_WANT_DH_RFC7919_8192
|
||||||
|
|
||||||
make CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
$MAKE_COMMAND CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
||||||
|
|
||||||
msg "test_suite_ssl: TLS 1.3 only, only PSK key exchange mode enabled"
|
msg "test_suite_ssl: TLS 1.3 only, only PSK key exchange mode enabled"
|
||||||
cd tests; ./test_suite_ssl; cd ..
|
cd tests; ./test_suite_ssl; cd ..
|
||||||
@@ -454,7 +454,7 @@ component_test_tls13_only_ephemeral () {
|
|||||||
scripts/config.py unset MBEDTLS_SSL_EARLY_DATA
|
scripts/config.py unset MBEDTLS_SSL_EARLY_DATA
|
||||||
|
|
||||||
scripts/config.py set MBEDTLS_TEST_HOOKS
|
scripts/config.py set MBEDTLS_TEST_HOOKS
|
||||||
make CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
$MAKE_COMMAND CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
||||||
|
|
||||||
msg "test_suite_ssl: TLS 1.3 only, only ephemeral key exchange mode"
|
msg "test_suite_ssl: TLS 1.3 only, only ephemeral key exchange mode"
|
||||||
cd tests; ./test_suite_ssl; cd ..
|
cd tests; ./test_suite_ssl; cd ..
|
||||||
@@ -473,7 +473,7 @@ component_test_tls13_only_ephemeral_ffdh () {
|
|||||||
scripts/config.py set MBEDTLS_TEST_HOOKS
|
scripts/config.py set MBEDTLS_TEST_HOOKS
|
||||||
scripts/config.py unset PSA_WANT_ALG_ECDH
|
scripts/config.py unset PSA_WANT_ALG_ECDH
|
||||||
|
|
||||||
make CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
$MAKE_COMMAND CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
||||||
|
|
||||||
msg "test_suite_ssl: TLS 1.3 only, only ephemeral ffdh key exchange mode"
|
msg "test_suite_ssl: TLS 1.3 only, only ephemeral ffdh key exchange mode"
|
||||||
cd tests; ./test_suite_ssl; cd ..
|
cd tests; ./test_suite_ssl; cd ..
|
||||||
@@ -498,7 +498,7 @@ component_test_tls13_only_psk_ephemeral () {
|
|||||||
scripts/config.py unset PSA_WANT_ALG_RSA_OAEP
|
scripts/config.py unset PSA_WANT_ALG_RSA_OAEP
|
||||||
scripts/config.py unset PSA_WANT_ALG_RSA_PSS
|
scripts/config.py unset PSA_WANT_ALG_RSA_PSS
|
||||||
|
|
||||||
make CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
$MAKE_COMMAND CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
||||||
|
|
||||||
msg "test_suite_ssl: TLS 1.3 only, only PSK ephemeral key exchange mode"
|
msg "test_suite_ssl: TLS 1.3 only, only PSK ephemeral key exchange mode"
|
||||||
cd tests; ./test_suite_ssl; cd ..
|
cd tests; ./test_suite_ssl; cd ..
|
||||||
@@ -524,7 +524,7 @@ component_test_tls13_only_psk_ephemeral_ffdh () {
|
|||||||
scripts/config.py unset PSA_WANT_ALG_RSA_OAEP
|
scripts/config.py unset PSA_WANT_ALG_RSA_OAEP
|
||||||
scripts/config.py unset PSA_WANT_ALG_RSA_PSS
|
scripts/config.py unset PSA_WANT_ALG_RSA_PSS
|
||||||
|
|
||||||
make CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
$MAKE_COMMAND CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
||||||
|
|
||||||
msg "test_suite_ssl: TLS 1.3 only, only PSK ephemeral ffdh key exchange mode"
|
msg "test_suite_ssl: TLS 1.3 only, only PSK ephemeral ffdh key exchange mode"
|
||||||
cd tests; ./test_suite_ssl; cd ..
|
cd tests; ./test_suite_ssl; cd ..
|
||||||
@@ -548,7 +548,7 @@ component_test_tls13_only_psk_all () {
|
|||||||
scripts/config.py unset PSA_WANT_ALG_RSA_OAEP
|
scripts/config.py unset PSA_WANT_ALG_RSA_OAEP
|
||||||
scripts/config.py unset PSA_WANT_ALG_RSA_PSS
|
scripts/config.py unset PSA_WANT_ALG_RSA_PSS
|
||||||
|
|
||||||
make CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
$MAKE_COMMAND CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
||||||
|
|
||||||
msg "test_suite_ssl: TLS 1.3 only, PSK and PSK ephemeral key exchange modes"
|
msg "test_suite_ssl: TLS 1.3 only, PSK and PSK ephemeral key exchange modes"
|
||||||
cd tests; ./test_suite_ssl; cd ..
|
cd tests; ./test_suite_ssl; cd ..
|
||||||
@@ -563,7 +563,7 @@ component_test_tls13_only_ephemeral_all () {
|
|||||||
scripts/config.py set MBEDTLS_SSL_EARLY_DATA
|
scripts/config.py set MBEDTLS_SSL_EARLY_DATA
|
||||||
|
|
||||||
scripts/config.py set MBEDTLS_TEST_HOOKS
|
scripts/config.py set MBEDTLS_TEST_HOOKS
|
||||||
make CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
$MAKE_COMMAND CFLAGS="'-DMBEDTLS_USER_CONFIG_FILE=\"../tests/configs/tls13-only.h\"'"
|
||||||
|
|
||||||
msg "test_suite_ssl: TLS 1.3 only, ephemeral and PSK ephemeral key exchange modes"
|
msg "test_suite_ssl: TLS 1.3 only, ephemeral and PSK ephemeral key exchange modes"
|
||||||
cd tests; ./test_suite_ssl; cd ..
|
cd tests; ./test_suite_ssl; cd ..
|
||||||
|
|||||||
@@ -14,10 +14,10 @@ component_test_no_x509_info () {
|
|||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
scripts/config.py unset MBEDTLS_MEMORY_BACKTRACE # too slow for tests
|
scripts/config.py unset MBEDTLS_MEMORY_BACKTRACE # too slow for tests
|
||||||
scripts/config.py set MBEDTLS_X509_REMOVE_INFO
|
scripts/config.py set MBEDTLS_X509_REMOVE_INFO
|
||||||
make CFLAGS='-Werror -O2'
|
$MAKE_COMMAND CFLAGS='-Werror -O2'
|
||||||
|
|
||||||
msg "test: full + MBEDTLS_X509_REMOVE_INFO" # ~ 10s
|
msg "test: full + MBEDTLS_X509_REMOVE_INFO" # ~ 10s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "test: ssl-opt.sh, full + MBEDTLS_X509_REMOVE_INFO" # ~ 1 min
|
msg "test: ssl-opt.sh, full + MBEDTLS_X509_REMOVE_INFO" # ~ 1 min
|
||||||
tests/ssl-opt.sh
|
tests/ssl-opt.sh
|
||||||
@@ -28,8 +28,8 @@ component_test_sw_inet_pton () {
|
|||||||
|
|
||||||
# MBEDTLS_TEST_HOOKS required for x509_crt_parse_cn_inet_pton
|
# MBEDTLS_TEST_HOOKS required for x509_crt_parse_cn_inet_pton
|
||||||
scripts/config.py set MBEDTLS_TEST_HOOKS
|
scripts/config.py set MBEDTLS_TEST_HOOKS
|
||||||
make CFLAGS="-DMBEDTLS_TEST_SW_INET_PTON"
|
$MAKE_COMMAND CFLAGS="-DMBEDTLS_TEST_SW_INET_PTON"
|
||||||
|
|
||||||
msg "test: default plus MBEDTLS_TEST_SW_INET_PTON"
|
msg "test: default plus MBEDTLS_TEST_SW_INET_PTON"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,12 +11,12 @@
|
|||||||
|
|
||||||
component_test_default_out_of_box () {
|
component_test_default_out_of_box () {
|
||||||
msg "build: make, default config (out-of-box)" # ~1min
|
msg "build: make, default config (out-of-box)" # ~1min
|
||||||
make
|
$MAKE_COMMAND
|
||||||
# Disable fancy stuff
|
# Disable fancy stuff
|
||||||
unset MBEDTLS_TEST_OUTCOME_FILE
|
unset MBEDTLS_TEST_OUTCOME_FILE
|
||||||
|
|
||||||
msg "test: main suites make, default config (out-of-box)" # ~10s
|
msg "test: main suites make, default config (out-of-box)" # ~10s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "selftest: make, default config (out-of-box)" # ~10s
|
msg "selftest: make, default config (out-of-box)" # ~10s
|
||||||
programs/test/selftest
|
programs/test/selftest
|
||||||
@@ -160,19 +160,19 @@ component_test_default_no_deprecated () {
|
|||||||
# configuration leaves something consistent.
|
# configuration leaves something consistent.
|
||||||
msg "build: make, default + MBEDTLS_DEPRECATED_REMOVED" # ~ 30s
|
msg "build: make, default + MBEDTLS_DEPRECATED_REMOVED" # ~ 30s
|
||||||
scripts/config.py set MBEDTLS_DEPRECATED_REMOVED
|
scripts/config.py set MBEDTLS_DEPRECATED_REMOVED
|
||||||
make CFLAGS='-O -Werror -Wall -Wextra'
|
$MAKE_COMMAND CFLAGS='-O -Werror -Wall -Wextra'
|
||||||
|
|
||||||
msg "test: make, default + MBEDTLS_DEPRECATED_REMOVED" # ~ 5s
|
msg "test: make, default + MBEDTLS_DEPRECATED_REMOVED" # ~ 5s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_full_no_deprecated () {
|
component_test_full_no_deprecated () {
|
||||||
msg "build: make, full_no_deprecated config" # ~ 30s
|
msg "build: make, full_no_deprecated config" # ~ 30s
|
||||||
scripts/config.py full_no_deprecated
|
scripts/config.py full_no_deprecated
|
||||||
make CFLAGS='-O -Werror -Wall -Wextra'
|
$MAKE_COMMAND CFLAGS='-O -Werror -Wall -Wextra'
|
||||||
|
|
||||||
msg "test: make, full_no_deprecated config" # ~ 5s
|
msg "test: make, full_no_deprecated config" # ~ 5s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "test: ensure that X509 has no direct dependency on BIGNUM_C"
|
msg "test: ensure that X509 has no direct dependency on BIGNUM_C"
|
||||||
not grep mbedtls_mpi library/libmbedx509.a
|
not grep mbedtls_mpi library/libmbedx509.a
|
||||||
@@ -186,10 +186,10 @@ component_test_full_no_deprecated_deprecated_warning () {
|
|||||||
scripts/config.py full_no_deprecated
|
scripts/config.py full_no_deprecated
|
||||||
scripts/config.py unset MBEDTLS_DEPRECATED_REMOVED
|
scripts/config.py unset MBEDTLS_DEPRECATED_REMOVED
|
||||||
scripts/config.py set MBEDTLS_DEPRECATED_WARNING
|
scripts/config.py set MBEDTLS_DEPRECATED_WARNING
|
||||||
make CFLAGS='-O -Werror -Wall -Wextra'
|
$MAKE_COMMAND CFLAGS='-O -Werror -Wall -Wextra'
|
||||||
|
|
||||||
msg "test: make, full_no_deprecated config, MBEDTLS_DEPRECATED_WARNING" # ~ 5s
|
msg "test: make, full_no_deprecated config, MBEDTLS_DEPRECATED_WARNING" # ~ 5s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_full_deprecated_warning () {
|
component_test_full_deprecated_warning () {
|
||||||
@@ -201,17 +201,17 @@ component_test_full_deprecated_warning () {
|
|||||||
# Expect warnings from '#warning' directives in check_config.h.
|
# Expect warnings from '#warning' directives in check_config.h.
|
||||||
# Note that gcc is required to allow the use of -Wno-error=cpp, which allows us to
|
# Note that gcc is required to allow the use of -Wno-error=cpp, which allows us to
|
||||||
# display #warning messages without them being treated as errors.
|
# display #warning messages without them being treated as errors.
|
||||||
make CC=gcc CFLAGS='-O -Werror -Wall -Wextra -Wno-error=cpp' lib programs
|
$MAKE_COMMAND CC=gcc CFLAGS='-O -Werror -Wall -Wextra -Wno-error=cpp' lib programs
|
||||||
|
|
||||||
msg "build: make tests, full config + MBEDTLS_DEPRECATED_WARNING, expect warnings" # ~ 30s
|
msg "build: make tests, full config + MBEDTLS_DEPRECATED_WARNING, expect warnings" # ~ 30s
|
||||||
# Set MBEDTLS_TEST_DEPRECATED to enable tests for deprecated features.
|
# Set MBEDTLS_TEST_DEPRECATED to enable tests for deprecated features.
|
||||||
# By default those are disabled when MBEDTLS_DEPRECATED_WARNING is set.
|
# By default those are disabled when MBEDTLS_DEPRECATED_WARNING is set.
|
||||||
# Expect warnings from '#warning' directives in check_config.h and
|
# Expect warnings from '#warning' directives in check_config.h and
|
||||||
# from the use of deprecated functions in test suites.
|
# from the use of deprecated functions in test suites.
|
||||||
make CC=gcc CFLAGS='-O -Werror -Wall -Wextra -Wno-error=deprecated-declarations -Wno-error=cpp -DMBEDTLS_TEST_DEPRECATED' tests
|
$MAKE_COMMAND CC=gcc CFLAGS='-O -Werror -Wall -Wextra -Wno-error=deprecated-declarations -Wno-error=cpp -DMBEDTLS_TEST_DEPRECATED' tests
|
||||||
|
|
||||||
msg "test: full config + MBEDTLS_TEST_DEPRECATED" # ~ 30s
|
msg "test: full config + MBEDTLS_TEST_DEPRECATED" # ~ 30s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "program demos: full config + MBEDTLS_TEST_DEPRECATED" # ~10s
|
msg "program demos: full config + MBEDTLS_TEST_DEPRECATED" # ~10s
|
||||||
tests/scripts/run_demos.py
|
tests/scripts/run_demos.py
|
||||||
@@ -220,7 +220,7 @@ component_test_full_deprecated_warning () {
|
|||||||
component_build_baremetal () {
|
component_build_baremetal () {
|
||||||
msg "build: make, baremetal config"
|
msg "build: make, baremetal config"
|
||||||
scripts/config.py baremetal
|
scripts/config.py baremetal
|
||||||
make CFLAGS="-O1 -Werror -I$PWD/framework/tests/include/baremetal-override/"
|
$MAKE_COMMAND CFLAGS="-O1 -Werror -I$PWD/framework/tests/include/baremetal-override/"
|
||||||
}
|
}
|
||||||
|
|
||||||
support_build_baremetal () {
|
support_build_baremetal () {
|
||||||
@@ -240,20 +240,20 @@ component_build_tfm () {
|
|||||||
cp tf-psa-crypto/configs/ext/crypto_config_profile_medium.h "$CRYPTO_CONFIG_H"
|
cp tf-psa-crypto/configs/ext/crypto_config_profile_medium.h "$CRYPTO_CONFIG_H"
|
||||||
|
|
||||||
msg "build: TF-M config, clang, armv7-m thumb2"
|
msg "build: TF-M config, clang, armv7-m thumb2"
|
||||||
make lib CC="clang" CFLAGS="--target=arm-linux-gnueabihf -march=armv7-m -mthumb -Os -std=c99 -Werror -Wall -Wextra -Wwrite-strings -Wpointer-arith -Wimplicit-fallthrough -Wshadow -Wvla -Wformat=2 -Wno-format-nonliteral -Wshadow -Wasm-operand-widths -Wunused -I../framework/tests/include/spe"
|
$MAKE_COMMAND lib CC="clang" CFLAGS="--target=arm-linux-gnueabihf -march=armv7-m -mthumb -Os -std=c99 -Werror -Wall -Wextra -Wwrite-strings -Wpointer-arith -Wimplicit-fallthrough -Wshadow -Wvla -Wformat=2 -Wno-format-nonliteral -Wshadow -Wasm-operand-widths -Wunused -I../framework/tests/include/spe"
|
||||||
|
|
||||||
msg "build: TF-M config, gcc native build"
|
msg "build: TF-M config, gcc native build"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make lib CC="gcc" CFLAGS="-Os -std=c99 -Werror -Wall -Wextra -Wwrite-strings -Wpointer-arith -Wshadow -Wvla -Wformat=2 -Wno-format-nonliteral -Wshadow -Wformat-signedness -Wlogical-op -I../framework/tests/include/spe"
|
$MAKE_COMMAND lib CC="gcc" CFLAGS="-Os -std=c99 -Werror -Wall -Wextra -Wwrite-strings -Wpointer-arith -Wshadow -Wvla -Wformat=2 -Wno-format-nonliteral -Wshadow -Wformat-signedness -Wlogical-op -I../framework/tests/include/spe"
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_malloc_0_null () {
|
component_test_malloc_0_null () {
|
||||||
msg "build: malloc(0) returns NULL (ASan+UBSan build)"
|
msg "build: malloc(0) returns NULL (ASan+UBSan build)"
|
||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
make CC=$ASAN_CC CFLAGS="'-DTF_PSA_CRYPTO_USER_CONFIG_FILE=\"$PWD/tests/configs/user-config-malloc-0-null.h\"' $ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
$MAKE_COMMAND CC=$ASAN_CC CFLAGS="'-DTF_PSA_CRYPTO_USER_CONFIG_FILE=\"$PWD/tests/configs/user-config-malloc-0-null.h\"' $ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: malloc(0) returns NULL (ASan+UBSan build)"
|
msg "test: malloc(0) returns NULL (ASan+UBSan build)"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "selftest: malloc(0) returns NULL (ASan+UBSan build)"
|
msg "selftest: malloc(0) returns NULL (ASan+UBSan build)"
|
||||||
# Just the calloc selftest. "make test" ran the others as part of the
|
# Just the calloc selftest. "make test" ran the others as part of the
|
||||||
@@ -288,24 +288,24 @@ component_test_no_platform () {
|
|||||||
scripts/config.py set MBEDTLS_PSA_DRIVER_GET_ENTROPY
|
scripts/config.py set MBEDTLS_PSA_DRIVER_GET_ENTROPY
|
||||||
# Note, _DEFAULT_SOURCE needs to be defined for platforms using glibc version >2.19,
|
# Note, _DEFAULT_SOURCE needs to be defined for platforms using glibc version >2.19,
|
||||||
# to re-enable platform integration features otherwise disabled in C99 builds
|
# to re-enable platform integration features otherwise disabled in C99 builds
|
||||||
make CC=gcc CFLAGS='-Werror -Wall -Wextra -std=c99 -pedantic -Os -D_DEFAULT_SOURCE' lib programs
|
$MAKE_COMMAND CC=gcc CFLAGS='-Werror -Wall -Wextra -std=c99 -pedantic -Os -D_DEFAULT_SOURCE' lib programs
|
||||||
make CC=gcc CFLAGS='-Werror -Wall -Wextra -Os' test
|
$MAKE_COMMAND CC=gcc CFLAGS='-Werror -Wall -Wextra -Os' test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_build_mbedtls_config_file () {
|
component_build_mbedtls_config_file () {
|
||||||
msg "build: make with MBEDTLS_CONFIG_FILE" # ~40s
|
msg "build: make with MBEDTLS_CONFIG_FILE" # ~40s
|
||||||
scripts/config.py -w full_config.h full
|
scripts/config.py -w full_config.h full
|
||||||
echo '#error "MBEDTLS_CONFIG_FILE is not working"' >"$CONFIG_H"
|
echo '#error "MBEDTLS_CONFIG_FILE is not working"' >"$CONFIG_H"
|
||||||
make CFLAGS="-I '$PWD' -DMBEDTLS_CONFIG_FILE='\"full_config.h\"'"
|
$MAKE_COMMAND CFLAGS="-I '$PWD' -DMBEDTLS_CONFIG_FILE='\"full_config.h\"'"
|
||||||
# Make sure this feature is enabled. We'll disable it in the next phase.
|
# Make sure this feature is enabled. We'll disable it in the next phase.
|
||||||
programs/test/query_compile_time_config MBEDTLS_SSL_ALL_ALERT_MESSAGES
|
programs/test/query_compile_time_config MBEDTLS_SSL_ALL_ALERT_MESSAGES
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
|
|
||||||
msg "build: make with MBEDTLS_CONFIG_FILE + MBEDTLS_USER_CONFIG_FILE"
|
msg "build: make with MBEDTLS_CONFIG_FILE + MBEDTLS_USER_CONFIG_FILE"
|
||||||
# In the user config, disable one feature (for simplicity, pick a feature
|
# In the user config, disable one feature (for simplicity, pick a feature
|
||||||
# that nothing else depends on).
|
# that nothing else depends on).
|
||||||
echo '#undef MBEDTLS_SSL_ALL_ALERT_MESSAGES' >user_config.h
|
echo '#undef MBEDTLS_SSL_ALL_ALERT_MESSAGES' >user_config.h
|
||||||
make CFLAGS="-I '$PWD' -DMBEDTLS_CONFIG_FILE='\"full_config.h\"' -DMBEDTLS_USER_CONFIG_FILE='\"user_config.h\"'"
|
$MAKE_COMMAND CFLAGS="-I '$PWD' -DMBEDTLS_CONFIG_FILE='\"full_config.h\"' -DMBEDTLS_USER_CONFIG_FILE='\"user_config.h\"'"
|
||||||
not programs/test/query_compile_time_config MBEDTLS_SSL_ALL_ALERT_MESSAGES
|
not programs/test/query_compile_time_config MBEDTLS_SSL_ALL_ALERT_MESSAGES
|
||||||
|
|
||||||
rm -f user_config.h full_config.h
|
rm -f user_config.h full_config.h
|
||||||
@@ -319,10 +319,10 @@ component_test_no_strings () {
|
|||||||
scripts/config.py unset MBEDTLS_ERROR_C
|
scripts/config.py unset MBEDTLS_ERROR_C
|
||||||
scripts/config.py set MBEDTLS_ERROR_STRERROR_DUMMY
|
scripts/config.py set MBEDTLS_ERROR_STRERROR_DUMMY
|
||||||
scripts/config.py unset MBEDTLS_VERSION_FEATURES
|
scripts/config.py unset MBEDTLS_VERSION_FEATURES
|
||||||
make CFLAGS='-Werror -Os'
|
$MAKE_COMMAND CFLAGS='-Werror -Os'
|
||||||
|
|
||||||
msg "test: no strings" # ~ 10s
|
msg "test: no strings" # ~ 10s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_memory_buffer_allocator_backtrace () {
|
component_test_memory_buffer_allocator_backtrace () {
|
||||||
|
|||||||
@@ -19,10 +19,10 @@ component_test_m32_no_asm () {
|
|||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
scripts/config.py unset MBEDTLS_HAVE_ASM
|
scripts/config.py unset MBEDTLS_HAVE_ASM
|
||||||
scripts/config.py unset MBEDTLS_AESNI_C # AESNI for 32-bit is tested in test_aesni_m32
|
scripts/config.py unset MBEDTLS_AESNI_C # AESNI for 32-bit is tested in test_aesni_m32
|
||||||
make CC=gcc CFLAGS="$ASAN_CFLAGS -m32" LDFLAGS="-m32 $ASAN_CFLAGS"
|
$MAKE_COMMAND CC=gcc CFLAGS="$ASAN_CFLAGS -m32" LDFLAGS="-m32 $ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: i386, make, gcc, no asm (ASan build)"
|
msg "test: i386, make, gcc, no asm (ASan build)"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
support_test_m32_no_asm () {
|
support_test_m32_no_asm () {
|
||||||
@@ -38,10 +38,10 @@ component_test_m32_o2 () {
|
|||||||
msg "build: i386, make, gcc -O2 (ASan build)" # ~ 30s
|
msg "build: i386, make, gcc -O2 (ASan build)" # ~ 30s
|
||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
scripts/config.py unset MBEDTLS_AESNI_C # AESNI for 32-bit is tested in test_aesni_m32
|
scripts/config.py unset MBEDTLS_AESNI_C # AESNI for 32-bit is tested in test_aesni_m32
|
||||||
make CC=gcc CFLAGS="$ASAN_CFLAGS -m32" LDFLAGS="-m32 $ASAN_CFLAGS"
|
$MAKE_COMMAND CC=gcc CFLAGS="$ASAN_CFLAGS -m32" LDFLAGS="-m32 $ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: i386, make, gcc -O2 (ASan build)"
|
msg "test: i386, make, gcc -O2 (ASan build)"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "test ssl-opt.sh, i386, make, gcc-O2"
|
msg "test ssl-opt.sh, i386, make, gcc-O2"
|
||||||
tests/ssl-opt.sh
|
tests/ssl-opt.sh
|
||||||
@@ -55,10 +55,10 @@ component_test_m32_everest () {
|
|||||||
msg "build: i386, Everest ECDH context (ASan build)" # ~ 6 min
|
msg "build: i386, Everest ECDH context (ASan build)" # ~ 6 min
|
||||||
scripts/config.py set MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED
|
scripts/config.py set MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED
|
||||||
scripts/config.py unset MBEDTLS_AESNI_C # AESNI for 32-bit is tested in test_aesni_m32
|
scripts/config.py unset MBEDTLS_AESNI_C # AESNI for 32-bit is tested in test_aesni_m32
|
||||||
make CC=gcc CFLAGS="$ASAN_CFLAGS -m32" LDFLAGS="-m32 $ASAN_CFLAGS"
|
$MAKE_COMMAND CC=gcc CFLAGS="$ASAN_CFLAGS -m32" LDFLAGS="-m32 $ASAN_CFLAGS"
|
||||||
|
|
||||||
msg "test: i386, Everest ECDH context - main suites (inc. selftests) (ASan build)" # ~ 50s
|
msg "test: i386, Everest ECDH context - main suites (inc. selftests) (ASan build)" # ~ 50s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "test: i386, Everest ECDH context - ECDH-related part of ssl-opt.sh (ASan build)" # ~ 5s
|
msg "test: i386, Everest ECDH context - ECDH-related part of ssl-opt.sh (ASan build)" # ~ 5s
|
||||||
tests/ssl-opt.sh -f ECDH
|
tests/ssl-opt.sh -f ECDH
|
||||||
@@ -75,10 +75,10 @@ support_test_m32_everest () {
|
|||||||
component_test_mx32 () {
|
component_test_mx32 () {
|
||||||
msg "build: 64-bit ILP32, make, gcc" # ~ 30s
|
msg "build: 64-bit ILP32, make, gcc" # ~ 30s
|
||||||
scripts/config.py full
|
scripts/config.py full
|
||||||
make CC=gcc CFLAGS='-O2 -Werror -Wall -Wextra -mx32' LDFLAGS='-mx32'
|
$MAKE_COMMAND CC=gcc CFLAGS='-O2 -Werror -Wall -Wextra -mx32' LDFLAGS='-mx32'
|
||||||
|
|
||||||
msg "test: 64-bit ILP32, make, gcc"
|
msg "test: 64-bit ILP32, make, gcc"
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
}
|
}
|
||||||
|
|
||||||
support_test_mx32 () {
|
support_test_mx32 () {
|
||||||
@@ -118,16 +118,16 @@ component_test_aesni () { # ~ 60s
|
|||||||
|
|
||||||
# test the intrinsics implementation
|
# test the intrinsics implementation
|
||||||
msg "AES tests, test intrinsics"
|
msg "AES tests, test intrinsics"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make CC=gcc CFLAGS='-Werror -Wall -Wextra -mpclmul -msse2 -maes'
|
$MAKE_COMMAND CC=gcc CFLAGS='-Werror -Wall -Wextra -mpclmul -msse2 -maes'
|
||||||
# check that the intrinsics implementation is in use - this should be used by default when
|
# check that the intrinsics implementation is in use - this should be used by default when
|
||||||
# supported by the compiler
|
# supported by the compiler
|
||||||
./tf-psa-crypto/programs/test/which_aes | grep -q "AESNI INTRINSICS"
|
./tf-psa-crypto/programs/test/which_aes | grep -q "AESNI INTRINSICS"
|
||||||
|
|
||||||
# test the asm implementation
|
# test the asm implementation
|
||||||
msg "AES tests, test assembly"
|
msg "AES tests, test assembly"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make CC=gcc CFLAGS='-Werror -Wall -Wextra -mno-pclmul -mno-sse2 -mno-aes'
|
$MAKE_COMMAND CC=gcc CFLAGS='-Werror -Wall -Wextra -mno-pclmul -mno-sse2 -mno-aes'
|
||||||
# check that the assembly implementation is in use - this should be used if the compiler
|
# check that the assembly implementation is in use - this should be used if the compiler
|
||||||
# does not support intrinsics
|
# does not support intrinsics
|
||||||
./tf-psa-crypto/programs/test/which_aes | grep -q "AESNI ASSEMBLY"
|
./tf-psa-crypto/programs/test/which_aes | grep -q "AESNI ASSEMBLY"
|
||||||
@@ -136,8 +136,8 @@ component_test_aesni () { # ~ 60s
|
|||||||
scripts/config.py unset MBEDTLS_AESNI_C
|
scripts/config.py unset MBEDTLS_AESNI_C
|
||||||
scripts/config.py unset MBEDTLS_AES_USE_HARDWARE_ONLY
|
scripts/config.py unset MBEDTLS_AES_USE_HARDWARE_ONLY
|
||||||
msg "AES tests, plain C"
|
msg "AES tests, plain C"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make CC=gcc CFLAGS='-O2 -Werror'
|
$MAKE_COMMAND CC=gcc CFLAGS='-O2 -Werror'
|
||||||
# check that the plain C implementation is present and the AESNI one is not
|
# check that the plain C implementation is present and the AESNI one is not
|
||||||
grep -q mbedtls_internal_aes_encrypt ./tf-psa-crypto/drivers/builtin/src/aes.o
|
grep -q mbedtls_internal_aes_encrypt ./tf-psa-crypto/drivers/builtin/src/aes.o
|
||||||
not grep -q mbedtls_aesni_crypt_ecb ./tf-psa-crypto/drivers/builtin/src/aesni.o
|
not grep -q mbedtls_aesni_crypt_ecb ./tf-psa-crypto/drivers/builtin/src/aesni.o
|
||||||
@@ -148,8 +148,8 @@ component_test_aesni () { # ~ 60s
|
|||||||
scripts/config.py set MBEDTLS_AESNI_C
|
scripts/config.py set MBEDTLS_AESNI_C
|
||||||
scripts/config.py set MBEDTLS_AES_USE_HARDWARE_ONLY
|
scripts/config.py set MBEDTLS_AES_USE_HARDWARE_ONLY
|
||||||
msg "AES tests, test AESNI only"
|
msg "AES tests, test AESNI only"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make CC=gcc CFLAGS='-Werror -Wall -Wextra -mpclmul -msse2 -maes'
|
$MAKE_COMMAND CC=gcc CFLAGS='-Werror -Wall -Wextra -mpclmul -msse2 -maes'
|
||||||
# check that the AESNI implementation is present and the plain C one is not
|
# check that the AESNI implementation is present and the plain C one is not
|
||||||
grep -q mbedtls_aesni_crypt_ecb ./tf-psa-crypto/drivers/builtin/src/aesni.o
|
grep -q mbedtls_aesni_crypt_ecb ./tf-psa-crypto/drivers/builtin/src/aesni.o
|
||||||
not grep -q mbedtls_internal_aes_encrypt ./tf-psa-crypto/drivers/builtin/src/aes.o
|
not grep -q mbedtls_internal_aes_encrypt ./tf-psa-crypto/drivers/builtin/src/aes.o
|
||||||
@@ -172,8 +172,8 @@ component_test_aesni_m32 () { # ~ 60s
|
|||||||
|
|
||||||
# test the intrinsics implementation with gcc
|
# test the intrinsics implementation with gcc
|
||||||
msg "AES tests, test intrinsics (gcc)"
|
msg "AES tests, test intrinsics (gcc)"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make CC=gcc CFLAGS='-m32 -Werror -Wall -Wextra' LDFLAGS='-m32'
|
$MAKE_COMMAND CC=gcc CFLAGS='-m32 -Werror -Wall -Wextra' LDFLAGS='-m32'
|
||||||
# check that we built intrinsics - this should be used by default when supported by the compiler
|
# check that we built intrinsics - this should be used by default when supported by the compiler
|
||||||
./tf-psa-crypto/programs/test/which_aes | grep -q "AESNI INTRINSICS"
|
./tf-psa-crypto/programs/test/which_aes | grep -q "AESNI INTRINSICS"
|
||||||
# check that both the AESNI and plain C implementations are present
|
# check that both the AESNI and plain C implementations are present
|
||||||
@@ -184,8 +184,8 @@ component_test_aesni_m32 () { # ~ 60s
|
|||||||
scripts/config.py set MBEDTLS_AESNI_C
|
scripts/config.py set MBEDTLS_AESNI_C
|
||||||
scripts/config.py set MBEDTLS_AES_USE_HARDWARE_ONLY
|
scripts/config.py set MBEDTLS_AES_USE_HARDWARE_ONLY
|
||||||
msg "AES tests, test AESNI only"
|
msg "AES tests, test AESNI only"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make CC=gcc CFLAGS='-m32 -Werror -Wall -Wextra -mpclmul -msse2 -maes' LDFLAGS='-m32'
|
$MAKE_COMMAND CC=gcc CFLAGS='-m32 -Werror -Wall -Wextra -mpclmul -msse2 -maes' LDFLAGS='-m32'
|
||||||
./tf-psa-crypto/programs/test/which_aes | grep -q "AESNI"
|
./tf-psa-crypto/programs/test/which_aes | grep -q "AESNI"
|
||||||
# check that the AESNI implementation is present and the plain C one is not
|
# check that the AESNI implementation is present and the plain C one is not
|
||||||
grep -q mbedtls_aesni_crypt_ecb ./tf-psa-crypto/drivers/builtin/src/aesni.o
|
grep -q mbedtls_aesni_crypt_ecb ./tf-psa-crypto/drivers/builtin/src/aesni.o
|
||||||
@@ -206,8 +206,8 @@ component_test_aesni_m32_clang () {
|
|||||||
|
|
||||||
# test the intrinsics implementation with clang
|
# test the intrinsics implementation with clang
|
||||||
msg "AES tests, test intrinsics (clang)"
|
msg "AES tests, test intrinsics (clang)"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make CC=clang CFLAGS='-m32 -Werror -Wall -Wextra' LDFLAGS='-m32'
|
$MAKE_COMMAND CC=clang CFLAGS='-m32 -Werror -Wall -Wextra' LDFLAGS='-m32'
|
||||||
# check that we built intrinsics - this should be used by default when supported by the compiler
|
# check that we built intrinsics - this should be used by default when supported by the compiler
|
||||||
./tf-psa-crypto/programs/test/which_aes | grep -q "AESNI INTRINSICS"
|
./tf-psa-crypto/programs/test/which_aes | grep -q "AESNI INTRINSICS"
|
||||||
# check that both the AESNI and plain C implementations are present
|
# check that both the AESNI and plain C implementations are present
|
||||||
@@ -227,51 +227,51 @@ component_build_aes_armce () {
|
|||||||
scripts/config.py set MBEDTLS_AES_USE_HARDWARE_ONLY
|
scripts/config.py set MBEDTLS_AES_USE_HARDWARE_ONLY
|
||||||
|
|
||||||
msg "MBEDTLS_AES_USE_HARDWARE_ONLY, clang, aarch64"
|
msg "MBEDTLS_AES_USE_HARDWARE_ONLY, clang, aarch64"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=aarch64-linux-gnu -march=armv8-a+crypto"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=aarch64-linux-gnu -march=armv8-a+crypto"
|
||||||
msg "clang, test aarch64 crypto instructions built"
|
msg "clang, test aarch64 crypto instructions built"
|
||||||
grep -E 'aes[a-z]+\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
grep -E 'aes[a-z]+\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
||||||
|
|
||||||
msg "MBEDTLS_AES_USE_HARDWARE_ONLY, clang, arm"
|
msg "MBEDTLS_AES_USE_HARDWARE_ONLY, clang, arm"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a72+crypto -marm"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a72+crypto -marm"
|
||||||
msg "clang, test A32 crypto instructions built"
|
msg "clang, test A32 crypto instructions built"
|
||||||
grep -E 'aes[0-9a-z]+.[0-9]\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
grep -E 'aes[0-9a-z]+.[0-9]\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
||||||
|
|
||||||
msg "MBEDTLS_AES_USE_HARDWARE_ONLY, clang, thumb"
|
msg "MBEDTLS_AES_USE_HARDWARE_ONLY, clang, thumb"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a32+crypto -mthumb"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a32+crypto -mthumb"
|
||||||
msg "clang, test T32 crypto instructions built"
|
msg "clang, test T32 crypto instructions built"
|
||||||
grep -E 'aes[0-9a-z]+.[0-9]\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
grep -E 'aes[0-9a-z]+.[0-9]\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
||||||
|
|
||||||
scripts/config.py unset MBEDTLS_AES_USE_HARDWARE_ONLY
|
scripts/config.py unset MBEDTLS_AES_USE_HARDWARE_ONLY
|
||||||
|
|
||||||
msg "MBEDTLS_AES_USE_both, clang, aarch64"
|
msg "MBEDTLS_AES_USE_both, clang, aarch64"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=aarch64-linux-gnu -march=armv8-a+crypto"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=aarch64-linux-gnu -march=armv8-a+crypto"
|
||||||
msg "clang, test aarch64 crypto instructions built"
|
msg "clang, test aarch64 crypto instructions built"
|
||||||
grep -E 'aes[a-z]+\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
grep -E 'aes[a-z]+\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
||||||
|
|
||||||
msg "MBEDTLS_AES_USE_both, clang, arm"
|
msg "MBEDTLS_AES_USE_both, clang, arm"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a72+crypto -marm"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a72+crypto -marm"
|
||||||
msg "clang, test A32 crypto instructions built"
|
msg "clang, test A32 crypto instructions built"
|
||||||
grep -E 'aes[0-9a-z]+.[0-9]\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
grep -E 'aes[0-9a-z]+.[0-9]\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
||||||
|
|
||||||
msg "MBEDTLS_AES_USE_both, clang, thumb"
|
msg "MBEDTLS_AES_USE_both, clang, thumb"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a32+crypto -mthumb"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a32+crypto -mthumb"
|
||||||
msg "clang, test T32 crypto instructions built"
|
msg "clang, test T32 crypto instructions built"
|
||||||
grep -E 'aes[0-9a-z]+.[0-9]\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
grep -E 'aes[0-9a-z]+.[0-9]\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
||||||
|
|
||||||
scripts/config.py unset MBEDTLS_AESCE_C
|
scripts/config.py unset MBEDTLS_AESCE_C
|
||||||
|
|
||||||
msg "no MBEDTLS_AESCE_C, clang, aarch64"
|
msg "no MBEDTLS_AESCE_C, clang, aarch64"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=aarch64-linux-gnu -march=armv8-a"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=aarch64-linux-gnu -march=armv8-a"
|
||||||
msg "clang, test aarch64 crypto instructions not built"
|
msg "clang, test aarch64 crypto instructions not built"
|
||||||
not grep -E 'aes[a-z]+\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
not grep -E 'aes[a-z]+\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
||||||
|
|
||||||
msg "no MBEDTLS_AESCE_C, clang, arm"
|
msg "no MBEDTLS_AESCE_C, clang, arm"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a72 -marm"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a72 -marm"
|
||||||
msg "clang, test A32 crypto instructions not built"
|
msg "clang, test A32 crypto instructions not built"
|
||||||
not grep -E 'aes[0-9a-z]+.[0-9]\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
not grep -E 'aes[0-9a-z]+.[0-9]\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
||||||
|
|
||||||
msg "no MBEDTLS_AESCE_C, clang, thumb"
|
msg "no MBEDTLS_AESCE_C, clang, thumb"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a32 -mthumb"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/aesce.o library/../${BUILTIN_SRC_PATH}/aesce.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a32 -mthumb"
|
||||||
msg "clang, test T32 crypto instructions not built"
|
msg "clang, test T32 crypto instructions not built"
|
||||||
not grep -E 'aes[0-9a-z]+.[0-9]\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
not grep -E 'aes[0-9a-z]+.[0-9]\s*[qv]' ${BUILTIN_SRC_PATH}/aesce.s
|
||||||
}
|
}
|
||||||
@@ -287,44 +287,44 @@ component_build_sha_armce () {
|
|||||||
# Test variations of SHA256 Armv8 crypto extensions
|
# Test variations of SHA256 Armv8 crypto extensions
|
||||||
scripts/config.py set MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY
|
scripts/config.py set MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY
|
||||||
msg "MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY clang, aarch64"
|
msg "MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY clang, aarch64"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/sha256.o library/../${BUILTIN_SRC_PATH}/sha256.s CC=clang CFLAGS="--target=aarch64-linux-gnu -march=armv8-a+crypto"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/sha256.o library/../${BUILTIN_SRC_PATH}/sha256.s CC=clang CFLAGS="--target=aarch64-linux-gnu -march=armv8-a+crypto"
|
||||||
msg "MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY clang, test aarch64 crypto instructions built"
|
msg "MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY clang, test aarch64 crypto instructions built"
|
||||||
grep -E 'sha256[a-z0-9]+\s+[qv]' ${BUILTIN_SRC_PATH}/sha256.s
|
grep -E 'sha256[a-z0-9]+\s+[qv]' ${BUILTIN_SRC_PATH}/sha256.s
|
||||||
|
|
||||||
msg "MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY clang, arm"
|
msg "MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY clang, arm"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/sha256.o library/../${BUILTIN_SRC_PATH}/sha256.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a72+crypto -marm"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/sha256.o library/../${BUILTIN_SRC_PATH}/sha256.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a72+crypto -marm"
|
||||||
msg "MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY clang, test A32 crypto instructions built"
|
msg "MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY clang, test A32 crypto instructions built"
|
||||||
grep -E 'sha256[a-z0-9]+.32\s+[qv]' ${BUILTIN_SRC_PATH}/sha256.s
|
grep -E 'sha256[a-z0-9]+.32\s+[qv]' ${BUILTIN_SRC_PATH}/sha256.s
|
||||||
scripts/config.py unset MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY
|
scripts/config.py unset MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_ONLY
|
||||||
|
|
||||||
scripts/config.py set MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_IF_PRESENT
|
scripts/config.py set MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_IF_PRESENT
|
||||||
msg "MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_IF_PRESENT clang, aarch64"
|
msg "MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_IF_PRESENT clang, aarch64"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/sha256.o library/../${BUILTIN_SRC_PATH}/sha256.s CC=clang CFLAGS="--target=aarch64-linux-gnu -march=armv8-a+crypto"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/sha256.o library/../${BUILTIN_SRC_PATH}/sha256.s CC=clang CFLAGS="--target=aarch64-linux-gnu -march=armv8-a+crypto"
|
||||||
msg "MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_IF_PRESENT clang, test aarch64 crypto instructions built"
|
msg "MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_IF_PRESENT clang, test aarch64 crypto instructions built"
|
||||||
grep -E 'sha256[a-z0-9]+\s+[qv]' ${BUILTIN_SRC_PATH}/sha256.s
|
grep -E 'sha256[a-z0-9]+\s+[qv]' ${BUILTIN_SRC_PATH}/sha256.s
|
||||||
scripts/config.py unset MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_IF_PRESENT
|
scripts/config.py unset MBEDTLS_SHA256_USE_ARMV8_A_CRYPTO_IF_PRESENT
|
||||||
|
|
||||||
# examine the disassembly for absence of SHA instructions
|
# examine the disassembly for absence of SHA instructions
|
||||||
msg "clang, test A32 crypto instructions not built"
|
msg "clang, test A32 crypto instructions not built"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/sha256.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a72 -marm"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/sha256.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a72 -marm"
|
||||||
not grep -E 'sha256[a-z0-9]+.32\s+[qv]' ${BUILTIN_SRC_PATH}/sha256.s
|
not grep -E 'sha256[a-z0-9]+.32\s+[qv]' ${BUILTIN_SRC_PATH}/sha256.s
|
||||||
|
|
||||||
msg "clang, test T32 crypto instructions not built"
|
msg "clang, test T32 crypto instructions not built"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/sha256.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a32 -mthumb"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/sha256.s CC=clang CFLAGS="--target=arm-linux-gnueabihf -mcpu=cortex-a32 -mthumb"
|
||||||
not grep -E 'sha256[a-z0-9]+.32\s+[qv]' ${BUILTIN_SRC_PATH}/sha256.s
|
not grep -E 'sha256[a-z0-9]+.32\s+[qv]' ${BUILTIN_SRC_PATH}/sha256.s
|
||||||
|
|
||||||
msg "clang, test aarch64 crypto instructions not built"
|
msg "clang, test aarch64 crypto instructions not built"
|
||||||
make -B library/../${BUILTIN_SRC_PATH}/sha256.s CC=clang CFLAGS="--target=aarch64-linux-gnu -march=armv8-a"
|
$MAKE_COMMAND -B library/../${BUILTIN_SRC_PATH}/sha256.s CC=clang CFLAGS="--target=aarch64-linux-gnu -march=armv8-a"
|
||||||
not grep -E 'sha256[a-z0-9]+\s+[qv]' ${BUILTIN_SRC_PATH}/sha256.s
|
not grep -E 'sha256[a-z0-9]+\s+[qv]' ${BUILTIN_SRC_PATH}/sha256.s
|
||||||
}
|
}
|
||||||
|
|
||||||
component_test_arm_linux_gnueabi_gcc_arm5vte () {
|
component_test_arm_linux_gnueabi_gcc_arm5vte () {
|
||||||
# Mimic Debian armel port
|
# Mimic Debian armel port
|
||||||
msg "test: ${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc -march=arm5vte, default config" # ~4m
|
msg "test: ${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc -march=arm5vte, default config" # ~4m
|
||||||
make CC="${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc" AR="${ARM_LINUX_GNUEABI_GCC_PREFIX}ar" CFLAGS='-Werror -Wall -Wextra -march=armv5te -O1'
|
$MAKE_COMMAND CC="${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc" AR="${ARM_LINUX_GNUEABI_GCC_PREFIX}ar" CFLAGS='-Werror -Wall -Wextra -march=armv5te -O1'
|
||||||
|
|
||||||
msg "test: main suites make, default config (out-of-box)" # ~7m 40s
|
msg "test: main suites make, default config (out-of-box)" # ~7m 40s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "selftest: make, default config (out-of-box)" # ~0s
|
msg "selftest: make, default config (out-of-box)" # ~0s
|
||||||
programs/test/selftest
|
programs/test/selftest
|
||||||
@@ -341,10 +341,10 @@ support_test_arm_linux_gnueabi_gcc_arm5vte () {
|
|||||||
# Some Thumb 1 asm is sensitive to optimisation level, so test both -O0 and -Os
|
# Some Thumb 1 asm is sensitive to optimisation level, so test both -O0 and -Os
|
||||||
component_test_arm_linux_gnueabi_gcc_thumb_1_opt_0 () {
|
component_test_arm_linux_gnueabi_gcc_thumb_1_opt_0 () {
|
||||||
msg "test: ${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc -O0, thumb 1, default config" # ~2m 10s
|
msg "test: ${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc -O0, thumb 1, default config" # ~2m 10s
|
||||||
make CC="${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc" CFLAGS='-std=c99 -Werror -Wextra -O0 -mcpu=arm1136j-s -mthumb'
|
$MAKE_COMMAND CC="${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc" CFLAGS='-std=c99 -Werror -Wextra -O0 -mcpu=arm1136j-s -mthumb'
|
||||||
|
|
||||||
msg "test: main suites make, default config (out-of-box)" # ~36m
|
msg "test: main suites make, default config (out-of-box)" # ~36m
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "selftest: make, default config (out-of-box)" # ~10s
|
msg "selftest: make, default config (out-of-box)" # ~10s
|
||||||
programs/test/selftest
|
programs/test/selftest
|
||||||
@@ -359,10 +359,10 @@ support_test_arm_linux_gnueabi_gcc_thumb_1_opt_0 () {
|
|||||||
|
|
||||||
component_test_arm_linux_gnueabi_gcc_thumb_1_opt_s () {
|
component_test_arm_linux_gnueabi_gcc_thumb_1_opt_s () {
|
||||||
msg "test: ${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc -Os, thumb 1, default config" # ~3m 10s
|
msg "test: ${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc -Os, thumb 1, default config" # ~3m 10s
|
||||||
make CC="${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc" CFLAGS='-std=c99 -Werror -Wextra -Os -mcpu=arm1136j-s -mthumb'
|
$MAKE_COMMAND CC="${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc" CFLAGS='-std=c99 -Werror -Wextra -Os -mcpu=arm1136j-s -mthumb'
|
||||||
|
|
||||||
msg "test: main suites make, default config (out-of-box)" # ~21m 10s
|
msg "test: main suites make, default config (out-of-box)" # ~21m 10s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "selftest: make, default config (out-of-box)" # ~2s
|
msg "selftest: make, default config (out-of-box)" # ~2s
|
||||||
programs/test/selftest
|
programs/test/selftest
|
||||||
@@ -377,10 +377,10 @@ support_test_arm_linux_gnueabi_gcc_thumb_1_opt_s () {
|
|||||||
|
|
||||||
component_test_arm_linux_gnueabihf_gcc_armv7 () {
|
component_test_arm_linux_gnueabihf_gcc_armv7 () {
|
||||||
msg "test: ${ARM_LINUX_GNUEABIHF_GCC_PREFIX}gcc -O2, A32, default config" # ~4m 30s
|
msg "test: ${ARM_LINUX_GNUEABIHF_GCC_PREFIX}gcc -O2, A32, default config" # ~4m 30s
|
||||||
make CC="${ARM_LINUX_GNUEABIHF_GCC_PREFIX}gcc" CFLAGS='-std=c99 -Werror -Wextra -O2 -march=armv7-a -marm'
|
$MAKE_COMMAND CC="${ARM_LINUX_GNUEABIHF_GCC_PREFIX}gcc" CFLAGS='-std=c99 -Werror -Wextra -O2 -march=armv7-a -marm'
|
||||||
|
|
||||||
msg "test: main suites make, default config (out-of-box)" # ~3m 30s
|
msg "test: main suites make, default config (out-of-box)" # ~3m 30s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "selftest: make, default config (out-of-box)" # ~0s
|
msg "selftest: make, default config (out-of-box)" # ~0s
|
||||||
programs/test/selftest
|
programs/test/selftest
|
||||||
@@ -395,10 +395,10 @@ support_test_arm_linux_gnueabihf_gcc_armv7 () {
|
|||||||
|
|
||||||
component_test_arm_linux_gnueabihf_gcc_thumb_2 () {
|
component_test_arm_linux_gnueabihf_gcc_thumb_2 () {
|
||||||
msg "test: ${ARM_LINUX_GNUEABIHF_GCC_PREFIX}gcc -Os, thumb 2, default config" # ~4m
|
msg "test: ${ARM_LINUX_GNUEABIHF_GCC_PREFIX}gcc -Os, thumb 2, default config" # ~4m
|
||||||
make CC="${ARM_LINUX_GNUEABIHF_GCC_PREFIX}gcc" CFLAGS='-std=c99 -Werror -Wextra -Os -march=armv7-a -mthumb'
|
$MAKE_COMMAND CC="${ARM_LINUX_GNUEABIHF_GCC_PREFIX}gcc" CFLAGS='-std=c99 -Werror -Wextra -Os -march=armv7-a -mthumb'
|
||||||
|
|
||||||
msg "test: main suites make, default config (out-of-box)" # ~3m 40s
|
msg "test: main suites make, default config (out-of-box)" # ~3m 40s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "selftest: make, default config (out-of-box)" # ~0s
|
msg "selftest: make, default config (out-of-box)" # ~0s
|
||||||
programs/test/selftest
|
programs/test/selftest
|
||||||
@@ -413,10 +413,10 @@ support_test_arm_linux_gnueabihf_gcc_thumb_2 () {
|
|||||||
|
|
||||||
component_test_aarch64_linux_gnu_gcc () {
|
component_test_aarch64_linux_gnu_gcc () {
|
||||||
msg "test: ${AARCH64_LINUX_GNU_GCC_PREFIX}gcc -O2, default config" # ~3m 50s
|
msg "test: ${AARCH64_LINUX_GNU_GCC_PREFIX}gcc -O2, default config" # ~3m 50s
|
||||||
make CC="${AARCH64_LINUX_GNU_GCC_PREFIX}gcc" CFLAGS='-std=c99 -Werror -Wextra -O2'
|
$MAKE_COMMAND CC="${AARCH64_LINUX_GNU_GCC_PREFIX}gcc" CFLAGS='-std=c99 -Werror -Wextra -O2'
|
||||||
|
|
||||||
msg "test: main suites make, default config (out-of-box)" # ~1m 50s
|
msg "test: main suites make, default config (out-of-box)" # ~1m 50s
|
||||||
make test
|
$MAKE_COMMAND test
|
||||||
|
|
||||||
msg "selftest: make, default config (out-of-box)" # ~0s
|
msg "selftest: make, default config (out-of-box)" # ~0s
|
||||||
programs/test/selftest
|
programs/test/selftest
|
||||||
@@ -433,7 +433,7 @@ support_test_aarch64_linux_gnu_gcc () {
|
|||||||
component_build_arm_none_eabi_gcc () {
|
component_build_arm_none_eabi_gcc () {
|
||||||
msg "build: ${ARM_NONE_EABI_GCC_PREFIX}gcc -O1, baremetal+debug" # ~ 10s
|
msg "build: ${ARM_NONE_EABI_GCC_PREFIX}gcc -O1, baremetal+debug" # ~ 10s
|
||||||
scripts/config.py baremetal
|
scripts/config.py baremetal
|
||||||
make CC="${ARM_NONE_EABI_GCC_PREFIX}gcc" AR="${ARM_NONE_EABI_GCC_PREFIX}ar" LD="${ARM_NONE_EABI_GCC_PREFIX}ld" CFLAGS='-std=c99 -Werror -Wall -Wextra -O1' lib
|
$MAKE_COMMAND CC="${ARM_NONE_EABI_GCC_PREFIX}gcc" AR="${ARM_NONE_EABI_GCC_PREFIX}ar" LD="${ARM_NONE_EABI_GCC_PREFIX}ld" CFLAGS='-std=c99 -Werror -Wall -Wextra -O1' lib
|
||||||
|
|
||||||
msg "size: ${ARM_NONE_EABI_GCC_PREFIX}gcc -O1, baremetal+debug"
|
msg "size: ${ARM_NONE_EABI_GCC_PREFIX}gcc -O1, baremetal+debug"
|
||||||
${ARM_NONE_EABI_GCC_PREFIX}size -t library/*.o
|
${ARM_NONE_EABI_GCC_PREFIX}size -t library/*.o
|
||||||
@@ -449,7 +449,7 @@ component_build_arm_linux_gnueabi_gcc_arm5vte () {
|
|||||||
# See https://github.com/Mbed-TLS/mbedtls/pull/2169 and comments.
|
# See https://github.com/Mbed-TLS/mbedtls/pull/2169 and comments.
|
||||||
# Build everything including programs, see for example
|
# Build everything including programs, see for example
|
||||||
# https://github.com/Mbed-TLS/mbedtls/pull/3449#issuecomment-675313720
|
# https://github.com/Mbed-TLS/mbedtls/pull/3449#issuecomment-675313720
|
||||||
make CC="${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc" AR="${ARM_LINUX_GNUEABI_GCC_PREFIX}ar" CFLAGS='-Werror -Wall -Wextra -march=armv5te -O1' LDFLAGS='-march=armv5te'
|
$MAKE_COMMAND CC="${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc" AR="${ARM_LINUX_GNUEABI_GCC_PREFIX}ar" CFLAGS='-Werror -Wall -Wextra -march=armv5te -O1' LDFLAGS='-march=armv5te'
|
||||||
|
|
||||||
msg "size: ${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc -march=armv5te -O1, baremetal+debug"
|
msg "size: ${ARM_LINUX_GNUEABI_GCC_PREFIX}gcc -march=armv5te -O1, baremetal+debug"
|
||||||
${ARM_LINUX_GNUEABI_GCC_PREFIX}size -t library/*.o
|
${ARM_LINUX_GNUEABI_GCC_PREFIX}size -t library/*.o
|
||||||
@@ -467,7 +467,7 @@ component_build_arm_none_eabi_gcc_arm5vte () {
|
|||||||
# This is an imperfect substitute for
|
# This is an imperfect substitute for
|
||||||
# component_build_arm_linux_gnueabi_gcc_arm5vte
|
# component_build_arm_linux_gnueabi_gcc_arm5vte
|
||||||
# in case the gcc-arm-linux-gnueabi toolchain is not available
|
# in case the gcc-arm-linux-gnueabi toolchain is not available
|
||||||
make CC="${ARM_NONE_EABI_GCC_PREFIX}gcc" AR="${ARM_NONE_EABI_GCC_PREFIX}ar" CFLAGS='-std=c99 -Werror -Wall -Wextra -march=armv5te -O1' LDFLAGS='-march=armv5te' SHELL='sh -x' lib
|
$MAKE_COMMAND CC="${ARM_NONE_EABI_GCC_PREFIX}gcc" AR="${ARM_NONE_EABI_GCC_PREFIX}ar" CFLAGS='-std=c99 -Werror -Wall -Wextra -march=armv5te -O1' LDFLAGS='-march=armv5te' SHELL='sh -x' lib
|
||||||
|
|
||||||
msg "size: ${ARM_NONE_EABI_GCC_PREFIX}gcc -march=armv5te -O1, baremetal+debug"
|
msg "size: ${ARM_NONE_EABI_GCC_PREFIX}gcc -march=armv5te -O1, baremetal+debug"
|
||||||
${ARM_NONE_EABI_GCC_PREFIX}size -t library/*.o
|
${ARM_NONE_EABI_GCC_PREFIX}size -t library/*.o
|
||||||
@@ -478,7 +478,7 @@ component_build_arm_none_eabi_gcc_arm5vte () {
|
|||||||
component_build_arm_none_eabi_gcc_m0plus () {
|
component_build_arm_none_eabi_gcc_m0plus () {
|
||||||
msg "build: ${ARM_NONE_EABI_GCC_PREFIX}gcc -mthumb -mcpu=cortex-m0plus, baremetal_size" # ~ 10s
|
msg "build: ${ARM_NONE_EABI_GCC_PREFIX}gcc -mthumb -mcpu=cortex-m0plus, baremetal_size" # ~ 10s
|
||||||
scripts/config.py baremetal_size
|
scripts/config.py baremetal_size
|
||||||
make CC="${ARM_NONE_EABI_GCC_PREFIX}gcc" AR="${ARM_NONE_EABI_GCC_PREFIX}ar" LD="${ARM_NONE_EABI_GCC_PREFIX}ld" CFLAGS='-std=c99 -Werror -Wall -Wextra -mthumb -mcpu=cortex-m0plus -Os' lib
|
$MAKE_COMMAND CC="${ARM_NONE_EABI_GCC_PREFIX}gcc" AR="${ARM_NONE_EABI_GCC_PREFIX}ar" LD="${ARM_NONE_EABI_GCC_PREFIX}ld" CFLAGS='-std=c99 -Werror -Wall -Wextra -mthumb -mcpu=cortex-m0plus -Os' lib
|
||||||
|
|
||||||
msg "size: ${ARM_NONE_EABI_GCC_PREFIX}gcc -mthumb -mcpu=cortex-m0plus -Os, baremetal_size"
|
msg "size: ${ARM_NONE_EABI_GCC_PREFIX}gcc -mthumb -mcpu=cortex-m0plus -Os, baremetal_size"
|
||||||
${ARM_NONE_EABI_GCC_PREFIX}size -t library/*.o
|
${ARM_NONE_EABI_GCC_PREFIX}size -t library/*.o
|
||||||
@@ -494,7 +494,7 @@ component_build_arm_none_eabi_gcc_no_udbl_division () {
|
|||||||
msg "build: ${ARM_NONE_EABI_GCC_PREFIX}gcc -DMBEDTLS_NO_UDBL_DIVISION, make" # ~ 10s
|
msg "build: ${ARM_NONE_EABI_GCC_PREFIX}gcc -DMBEDTLS_NO_UDBL_DIVISION, make" # ~ 10s
|
||||||
scripts/config.py baremetal
|
scripts/config.py baremetal
|
||||||
scripts/config.py set MBEDTLS_NO_UDBL_DIVISION
|
scripts/config.py set MBEDTLS_NO_UDBL_DIVISION
|
||||||
make CC="${ARM_NONE_EABI_GCC_PREFIX}gcc" AR="${ARM_NONE_EABI_GCC_PREFIX}ar" LD="${ARM_NONE_EABI_GCC_PREFIX}ld" CFLAGS='-std=c99 -Werror -Wall -Wextra' lib
|
$MAKE_COMMAND CC="${ARM_NONE_EABI_GCC_PREFIX}gcc" AR="${ARM_NONE_EABI_GCC_PREFIX}ar" LD="${ARM_NONE_EABI_GCC_PREFIX}ld" CFLAGS='-std=c99 -Werror -Wall -Wextra' lib
|
||||||
echo "Checking that software 64-bit division is not required"
|
echo "Checking that software 64-bit division is not required"
|
||||||
not grep __aeabi_uldiv library/*.o
|
not grep __aeabi_uldiv library/*.o
|
||||||
not grep __aeabi_uldiv ${PSA_CORE_PATH}/*.o
|
not grep __aeabi_uldiv ${PSA_CORE_PATH}/*.o
|
||||||
@@ -505,7 +505,7 @@ component_build_arm_none_eabi_gcc_no_64bit_multiplication () {
|
|||||||
msg "build: ${ARM_NONE_EABI_GCC_PREFIX}gcc MBEDTLS_NO_64BIT_MULTIPLICATION, make" # ~ 10s
|
msg "build: ${ARM_NONE_EABI_GCC_PREFIX}gcc MBEDTLS_NO_64BIT_MULTIPLICATION, make" # ~ 10s
|
||||||
scripts/config.py baremetal
|
scripts/config.py baremetal
|
||||||
scripts/config.py set MBEDTLS_NO_64BIT_MULTIPLICATION
|
scripts/config.py set MBEDTLS_NO_64BIT_MULTIPLICATION
|
||||||
make CC="${ARM_NONE_EABI_GCC_PREFIX}gcc" AR="${ARM_NONE_EABI_GCC_PREFIX}ar" LD="${ARM_NONE_EABI_GCC_PREFIX}ld" CFLAGS='-std=c99 -Werror -O1 -march=armv6-m -mthumb' lib
|
$MAKE_COMMAND CC="${ARM_NONE_EABI_GCC_PREFIX}gcc" AR="${ARM_NONE_EABI_GCC_PREFIX}ar" LD="${ARM_NONE_EABI_GCC_PREFIX}ld" CFLAGS='-std=c99 -Werror -O1 -march=armv6-m -mthumb' lib
|
||||||
echo "Checking that software 64-bit multiplication is not required"
|
echo "Checking that software 64-bit multiplication is not required"
|
||||||
not grep __aeabi_lmul library/*.o
|
not grep __aeabi_lmul library/*.o
|
||||||
not grep __aeabi_lmul ${PSA_CORE_PATH}/*.o
|
not grep __aeabi_lmul ${PSA_CORE_PATH}/*.o
|
||||||
@@ -518,17 +518,17 @@ component_build_arm_clang_thumb () {
|
|||||||
scripts/config.py baremetal
|
scripts/config.py baremetal
|
||||||
|
|
||||||
msg "build: clang thumb 2, make"
|
msg "build: clang thumb 2, make"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make CC="clang" CFLAGS='-std=c99 -Werror -Os --target=arm-linux-gnueabihf -march=armv7-m -mthumb' lib
|
$MAKE_COMMAND CC="clang" CFLAGS='-std=c99 -Werror -Os --target=arm-linux-gnueabihf -march=armv7-m -mthumb' lib
|
||||||
|
|
||||||
# Some Thumb 1 asm is sensitive to optimisation level, so test both -O0 and -Os
|
# Some Thumb 1 asm is sensitive to optimisation level, so test both -O0 and -Os
|
||||||
msg "build: clang thumb 1 -O0, make"
|
msg "build: clang thumb 1 -O0, make"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make CC="clang" CFLAGS='-std=c99 -Werror -O0 --target=arm-linux-gnueabihf -mcpu=arm1136j-s -mthumb' lib
|
$MAKE_COMMAND CC="clang" CFLAGS='-std=c99 -Werror -O0 --target=arm-linux-gnueabihf -mcpu=arm1136j-s -mthumb' lib
|
||||||
|
|
||||||
msg "build: clang thumb 1 -Os, make"
|
msg "build: clang thumb 1 -Os, make"
|
||||||
make clean
|
$MAKE_COMMAND clean
|
||||||
make CC="clang" CFLAGS='-std=c99 -Werror -Os --target=arm-linux-gnueabihf -mcpu=arm1136j-s -mthumb' lib
|
$MAKE_COMMAND CC="clang" CFLAGS='-std=c99 -Werror -Os --target=arm-linux-gnueabihf -mcpu=arm1136j-s -mthumb' lib
|
||||||
}
|
}
|
||||||
|
|
||||||
component_build_armcc () {
|
component_build_armcc () {
|
||||||
|
|||||||
@@ -83,7 +83,7 @@ component_test_suite_with_psasim()
|
|||||||
helper_psasim_build client
|
helper_psasim_build client
|
||||||
|
|
||||||
msg "build test suites"
|
msg "build test suites"
|
||||||
make PSASIM=1 CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS" tests
|
$MAKE_COMMAND PSASIM=1 CFLAGS="$ASAN_CFLAGS" LDFLAGS="$ASAN_CFLAGS" tests
|
||||||
|
|
||||||
helper_psasim_server start
|
helper_psasim_server start
|
||||||
|
|
||||||
@@ -93,7 +93,7 @@ component_test_suite_with_psasim()
|
|||||||
export SKIP_TEST_SUITES
|
export SKIP_TEST_SUITES
|
||||||
|
|
||||||
msg "run test suites"
|
msg "run test suites"
|
||||||
make PSASIM=1 test
|
$MAKE_COMMAND PSASIM=1 test
|
||||||
|
|
||||||
helper_psasim_server kill
|
helper_psasim_server kill
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user