Valerio Setti
46e8fd8263
test: sha: test SHA224 and SHA256 separately
...
This is meant to adapt to the new library design in which
SHA224 and SHA256 can be built independently from each other.
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2022-12-14 10:58:02 +01:00
Valerio Setti
898e7a3afe
test: sha: test SHA384 and SHA512 separately
...
This is meant to adapt to the new library design in which
SHA384 and SHA512 can be built independently from each other.
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2022-12-14 10:50:54 +01:00
Manuel Pégourié-Gonnard
2b70a3f831
Merge pull request #6558 from lpy4105/6416-psa_macros_name_typo
...
check_names: extend typo check to PSA macro/enum names
2022-12-13 09:56:27 +01:00
Manuel Pégourié-Gonnard
48232ed2c1
Merge pull request #6743 from minosgalanakis/bignum/implement_modular_negation
...
Bignum: Implement fixed width modular negation
2022-12-13 09:54:38 +01:00
Manuel Pégourié-Gonnard
a9ac61203b
Merge pull request #6666 from daverodgman/fast_unaligned
...
Fast unaligned memory access macros
2022-12-12 12:18:17 +01:00
Minos Galanakis
9a60b2373b
bignum_mod_raw testsuite: Refactored mpi_mod_raw_neg()
.
...
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2022-12-12 11:13:56 +00:00
Minos Galanakis
6118a3e5aa
test_suite_bignumg_mod_raw: Added test for mpi_mod_raw_neg
...
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2022-12-12 11:13:56 +00:00
Manuel Pégourié-Gonnard
cd98805bd7
Merge pull request #6683 from mpg/optimize-with-asan
...
Optimize with asan
2022-12-12 11:58:23 +01:00
Manuel Pégourié-Gonnard
cd98b939b6
Merge pull request #6750 from tom-cosgrove-arm/issue-6023-mod_inv_prime
...
Bignum: Implement mbedtls_mpi_mod_raw_inv_prime()
2022-12-12 09:52:21 +01:00
Manuel Pégourié-Gonnard
1a100b69a4
Merge pull request #6705 from davidhorstmann-arm/code-style-script-non-corrected
...
Add code style correction script
2022-12-09 09:41:14 +01:00
Tom Cosgrove
6129268fee
Bignum: Implement mbedtls_mpi_mod_raw_inv_prime() and tests
...
Fixes #6023 .
Signed-off-by: Tom Cosgrove <tom.cosgrove@arm.com>
2022-12-08 09:44:10 +00:00
Tom Cosgrove
a7f0d7b029
mbedtls_mpi_core_exp_mod() ouuput may alias input A
...
Signed-off-by: Tom Cosgrove <tom.cosgrove@arm.com>
2022-12-08 08:46:28 +00:00
Dave Rodgman
90af1a10ab
Merge pull request #6734 from daverodgman/fix_test_dep_spelling
...
Fix spelling of test dependency
2022-12-07 09:06:29 +00:00
Janos Follath
d45924d862
Merge pull request #6733 from tom-cosgrove-arm/issue-6293-mod_exp-memory
...
Have mbedtls_mpi_core_exp_mod() take a temporary instead of allocating memory
2022-12-07 08:32:31 +00:00
Dave Rodgman
1fe45295d7
Merge pull request #6685 from gilles-peskine-arm/valgrind-cf-skip-tests
...
Rationalize Valgrind tests
2022-12-06 18:39:32 +00:00
David Horstmann
92b5ac1a47
Add all.sh component to test with code style
...
Run the main test suites after running code style correction to check
that code style correction does not break these tests.
Signed-off-by: David Horstmann <david.horstmann@arm.com>
2022-12-06 17:44:30 +00:00
Dave Rodgman
92011eef34
Merge pull request #6717 from tom-cosgrove-arm/fix-typos-2212
...
Fix typos prior to release
2022-12-06 15:00:34 +00:00
Dave Rodgman
614688711d
Fix spelling of test dependency
...
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2022-12-06 14:44:08 +00:00
Tom Cosgrove
0a0ddedfb7
Have mbedtls_mpi_core_exp_mod() take a temporary instead of allocating memory
...
Last PR needed for #6293
Signed-off-by: Tom Cosgrove <tom.cosgrove@arm.com>
2022-12-06 14:37:18 +00:00
Tom Cosgrove
f51f972d67
Apply review comments
...
Signed-off-by: Tom Cosgrove <tom.cosgrove@arm.com>
2022-12-05 15:47:40 +00:00
Tom Cosgrove
1797b05602
Fix typos prior to release
...
Signed-off-by: Tom Cosgrove <tom.cosgrove@arm.com>
2022-12-04 17:19:59 +00:00
Tom Cosgrove
62b20488f1
Implement mbedtls_mpi_mod_sub()
...
Signed-off-by: Tom Cosgrove <tom.cosgrove@arm.com>
2022-12-01 14:27:37 +00:00
Dave Rodgman
481a5e427b
Improve parsing of test data
...
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2022-12-01 13:31:20 +00:00
Dave Rodgman
c3902ac661
Merge pull request #6698 from wernerlewis/bignum_mod_py
...
Bignum: Enable test generation from bignum_mod.py
2022-12-01 11:48:14 +00:00
Dave Rodgman
7fc53dd83d
Suppress over-eager compiler warnings in tests
...
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2022-12-01 11:42:29 +00:00
Paul Elliott
266f79c136
Merge pull request #6426 from aditya-deshpande-arm/driver-wrapper-key-agreement
...
Add driver dispatch layer for raw key agreement, along with test call for transparent drivers.
2022-12-01 11:40:52 +00:00
Dave Rodgman
9dc55ba932
Suppress over-eager compiler warnings in test code
...
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2022-12-01 10:49:57 +00:00
Dave Rodgman
63e6a88874
Suppress over-eager compiler warning in tests
...
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2022-12-01 10:01:08 +00:00
Dave Rodgman
fb5fedcd00
Add tests for alignment.h
...
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2022-12-01 09:40:03 +00:00
Werner Lewis
c84b731941
Enable test generation from bignum_mod.py
...
Signed-off-by: Werner Lewis <werner.lewis@arm.com>
2022-11-30 14:43:31 +00:00
Manuel Pégourié-Gonnard
fe549a76e4
Add comment about use of ASAN_CFLAGS
...
Signed-off-by: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com>
2022-11-30 12:38:58 +01:00
Manuel Pégourié-Gonnard
30d9466762
Only run what we need from compat.sh
...
Also, comment why we run those tests.
Signed-off-by: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com>
2022-11-30 12:38:58 +01:00
Tom Cosgrove
fc2ac75453
Fix the name of basic-build-test.sh within the file
...
Signed-off-by: Tom Cosgrove <tom.cosgrove@arm.com>
2022-11-30 11:13:00 +00:00
Gilles Peskine
72bffe02b7
Merge pull request #6663 from davidhorstmann-arm/fix-typo-unsupported
...
Fix typo 'unsupoported' -> 'unsupported'
2022-11-29 21:44:27 +01:00
Gilles Peskine
edaa17b350
Merge pull request #6547 from yanesca/extract_mod_exp_from_prototype
...
Bignum: Extract mod exp from prototype
2022-11-29 21:40:07 +01:00
Gilles Peskine
d1bc6da3d3
Fix the build with MBEDTLS_TEST_HOOKS && !MBEDTLS_USE_PSA_CRYPTO
...
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2022-11-29 21:14:19 +01:00
Aditya Deshpande
b6bc7524f9
Minor formatting fixes to address code review comments
...
Signed-off-by: Aditya Deshpande <aditya.deshpande@arm.com>
2022-11-29 16:53:29 +00:00
Gilles Peskine
0c67160b00
Valgrind for constant flow: skip non-CF test suites
...
When testing under Valgrind for constant flow, skip test suites that don't
have any constant-flow annotations, since the testing wouldn't do anything
more that testing with ordinary Valgrind (component_test_valgrind and
component_test_valgrind_psa). This is a significant time saving since
testing with Valgrind is very slow.
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2022-11-29 16:46:06 +01:00
Gilles Peskine
df3dd4c3bc
Test MBEDTLS_USE_PSA_CRYPTO with Valgrind
...
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2022-11-29 16:46:06 +01:00
Gilles Peskine
3ffd6bce81
Create a separate test suite for constant-time functions
...
This is the first step in arranging that functions from constant_time.c are
tested in test_suite_constant_time.function.
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2022-11-29 15:44:21 +01:00
Gilles Peskine
77e68c3176
Move constant-time HMAC testing to its own suite
...
These are very CPU-intensive, so make it easy to skip them. And conversely,
make it easy to run them without the growing body of SSL tests.
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2022-11-29 15:42:36 +01:00
Gilles Peskine
bfec9d0df7
Merge pull request #6676 from davidhorstmann-arm/cmake-get-skip-test-from-env
...
Tell cmake to get SKIP_TEST_SUITES from ENV
2022-11-29 14:25:50 +01:00
Manuel Pégourié-Gonnard
0b9b560770
Merge pull request #6601 from valeriosetti/issue6502
...
Avoid assumptions about implementation in EC J-PAKE tests
2022-11-29 11:21:23 +01:00
Manuel Pégourié-Gonnard
f9720cfa78
Merge pull request #6670 from gilles-peskine-arm/pkcs7-use-after-free-20221127
...
PKCS7: Fix some memory management errors
2022-11-29 11:17:27 +01:00
Manuel Pégourié-Gonnard
ffc330fafa
Merge pull request #6264 from hannestschofenig/rfc9146_2
...
CID update to RFC 9146
2022-11-29 09:25:14 +01:00
Manuel Pégourié-Gonnard
66f09834ea
Enable optimisation with Asan with make in all.sh
...
All builds using ASAN_CFLAGS were with Asan but no optimisation, making
them particularly slow. Indeed, we were overwriting CFLAGS which
defaults to -O2 and not using any -O in the replacement. (CMake already has
optimisations on with ASan.)
While at it, also remove -Wall -Wextra which are redundant as they are
already part of WARNING_CFLAGS which we are not overwriting.
Signed-off-by: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com>
2022-11-29 09:12:12 +01:00
Gilles Peskine
a13f5eb7b8
Add missing dependency for the fuzzer-constructed test data
...
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2022-11-28 21:30:04 +01:00
Dave Rodgman
d98ac8b75e
Merge remote-tracking branch 'dave/fast_xor' into fast_unaligned
2022-11-28 15:06:25 +00:00
Aditya Deshpande
1ac41dec09
Add test function for opaque driver (simply returns PSA_ERROR_NOT_SUPPORTED), and address other review comments.
...
Signed-off-by: Aditya Deshpande <aditya.deshpande@arm.com>
2022-11-28 14:46:30 +00:00
Valerio Setti
a34d0308cc
test: psa_pake: fix dependency
...
Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2022-11-28 11:46:36 +01:00