Andrzej Kurek
e05b17fb85
Update depends.py
...
Remove old and add new dependencies.
Introduce a way to handle non-trivial problems
stemming from exclusive group testing.
Exclude SHA256 and SHA512, as these are tested
in SHA224 and SHA384 jobs, respectively.
Change config.h to mbedtls_config.h).
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
c19fb08dd3
Add missing ECDH dependency in tls 1.3 client
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
e64bd43495
Add missing ECP and ECDH dependencies in ssl test suites
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
8e44139ca0
Add missing CURVE25519 requirements to TLS 1.3 tests
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
84f30f2eb0
Add missing SHA256 dependency
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
e38b788b79
Add missing key exchange dependencies
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
68327748d3
Add missing dependencies
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
90e8204476
Add missing SHA256 and ECDSA_C dependencies in test_suite_ssl
...
Most of the tests (including those using endpoint_init functions) parse
certificates that require MBEDTLS_SHA256_C to be present.
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
0abebebe6d
Refactor ssl test suite to use pointers more
...
This way it's easier to track structures that are partially set up.
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
46a987367c
Formatting fix
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
084334c8f2
Compile constant time masking and hmac if there are suites using MAC
...
This is used in TLS 1.2 authentication with NULL cipher,
when there are no TLS_CBC suites.
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
2d59dbc032
Use TLS prf only if TLS 1.2 is compiled in
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
894edde991
Add tls prf handling when there's no SHA256 or SHA384
...
Return a null prf function pointer and check for it when populating transform.
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
f502bcb13e
Fix missing AES dependencies
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Gilles Peskine
34a1557df6
Add domains for symmetric ciphers
...
Add a domain for cipher base algorithms (block permutations and stream
ciphers), a domain for block cipher chaining modes and a domain for
block cipher padding modes.
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Gilles Peskine
c3b4deeb6c
When exercising key exchanges, don't build the test suites
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Gilles Peskine
584c24ace4
Declare more reverse dependencies
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Gilles Peskine
b1284cf6bc
Don't test builds with only deprecated hashes
...
Don't try to build with only SHA-1 or with only RIPEMD160 or with only
MD{2,4,5}.
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Gilles Peskine
bf7537d0a9
Use the full config as the baseline for all jobs
...
Start each job from the full config minus some memory management
settings and the job-specific settings.
The original content of config.h no longer influences the
configurations used for the jobs (but it still influences what jobs
may run, in that the set of jobs is partly built by parsing #define
and //#define lines in config.h).
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Gilles Peskine
e85163bb5c
Simplify final passed/failed reporting
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Gilles Peskine
0fa7cbeeb9
Add basic support for colored output
...
Show "pass" lines in green and "fail" lines in red.
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Gilles Peskine
54aa5c6957
Factor running config.pl into its own function
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Gilles Peskine
46c8256547
Flush log output after each line
...
Otherwise the output can be out of order when redirected.
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Gilles Peskine
b39e3ecee6
New script to exercise compilation options
...
Unify curves.pl, key-exchanges.pl, depends-pkalgs.pl and
depends-hashes.pl into a single, newly-written script.
For curves, key exchanges and hashes, in addition to testing
all-but-one settings in the group like the old scripts, also run the
tests with a single option in the group.
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
e40b92178d
Fix missing padding dependencies
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Andrzej Kurek
252283f2aa
Fix missing cipher mode dependencies
...
Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
2022-10-19 08:35:08 -04:00
Janos Follath
7cd1ebe0bb
Merge pull request #6296 from gilles-peskine-arm/test_data_generation-pr_6093_followup
...
Minor fixes to test_data_generation.py
2022-10-18 13:38:28 +01:00
Gilles Peskine
47da7bfac8
Merge pull request #6434 from gilles-peskine-arm/lmots_import_export_test-memory_leak
...
LMS: Fix memory leak if unit test fails
2022-10-17 17:57:59 +02:00
Gilles Peskine
503d09b52d
Fix memory leak if unit test fails
...
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2022-10-17 12:27:43 +02:00
Manuel Pégourié-Gonnard
6c6f04b651
Merge pull request #6419 from mpg/fix-assert-alloc-usage
...
Fix usage of ASSERT_ALLOC()
2022-10-17 12:10:48 +02:00
Dave Rodgman
f33da19dfb
Merge pull request #6413 from daverodgman/update_docs_links
...
Update documentation links
2022-10-14 17:42:48 +01:00
Gilles Peskine
8874cd570e
Merge pull request #4826 from RcColes/development
...
Add LMS implementation
2022-10-14 18:33:01 +02:00
Dave Rodgman
f1ebf128e7
Fix capitalisation
...
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2022-10-14 10:48:52 +01:00
Dave Rodgman
ce164b7016
Update SUPPORT.md
...
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2022-10-14 10:47:04 +01:00
Dave Rodgman
032b594ec9
Update SUPPORT.md
...
Co-authored-by: Paul Elliott <62069445+paul-elliott-arm@users.noreply.github.com>
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2022-10-14 10:40:56 +01:00
Manuel Pégourié-Gonnard
b3c30907d6
Merge pull request #6383 from mprse/aead_driver_test
...
Enable testing of AEAD drivers with libtestdriver1
2022-10-14 11:11:01 +02:00
Manuel Pégourié-Gonnard
47b8de834d
Fix usage of ASSERT_ALLOC()
...
The second argument is the number of elements of the type the first
argument is pointing to, so we shouldn't be using sizeof there.
This was resulting in overly large allocations.
Signed-off-by: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com>
2022-10-14 09:35:55 +02:00
Gilles Peskine
fa65237fd4
Fix which config header MBEDTLS_LMS_xxx is unset from
...
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2022-10-13 22:05:38 +02:00
Gilles Peskine
31c2dcb611
Fix file names in reproduction instructions in test data
...
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2022-10-13 20:48:15 +02:00
Gilles Peskine
2875aa7b01
Fix instructions and test data for pyhsslms interop tests
...
The test data was invalid because it had the extra 4-byte prefix for HSS.
Regenerate it (which produces completely new signatures since it is
randomized).
Rearrange the reproduction instructions for the second test case so that it
shows more clearly how to generate a second signature with the same private
key.
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2022-10-13 20:45:05 +02:00
Raef Coles
8bccc999d9
Don't mention error type in LMS test comments
...
Signed-off-by: Raef Coles <raef.coles@arm.com>
2022-10-13 17:57:31 +01:00
Raef Coles
6d7d94a821
Use correct export length in LMS export tests
...
Signed-off-by: Raef Coles <raef.coles@arm.com>
2022-10-13 17:55:46 +01:00
Raef Coles
aa9d52bcdc
Rename LMS private key files to match library name
...
Signed-off-by: Raef Coles <raef.coles@arm.com>
2022-10-13 17:53:40 +01:00
Raef Coles
f8bfe2783b
Remove bad character from LMS test case
...
Signed-off-by: Raef Coles <raef.coles@arm.com>
2022-10-13 17:35:28 +01:00
Raef Coles
d543697092
Fix minor type in LMS test description
...
Signed-off-by: Raef Coles <raef.coles@arm.com>
2022-10-13 17:06:42 +01:00
Raef Coles
a2514f622f
Update pyhsslms test instructions with script
...
Due to tool name conflict hampering data reproduction
Signed-off-by: Raef Coles <raef.coles@arm.com>
2022-10-13 17:04:21 +01:00
Raef Coles
1951259a10
Update how lms.c imports platform.h
...
Signed-off-by: Raef Coles <raef.coles@arm.com>
2022-10-13 16:47:13 +01:00
Raef Coles
ce18e528ff
Rename LMS private key files
...
And remove now-unnecessary modification to check_files.py
Signed-off-by: Raef Coles <raef.coles@arm.com>
2022-10-13 16:45:05 +01:00
Raef Coles
e4d96b804c
Update LMS and LMOTS test comments
...
Signed-off-by: Raef Coles <raef.coles@arm.com>
2022-10-13 16:45:05 +01:00
Raef Coles
493724e3c2
Check correct output size in LMOTS export test
...
Signed-off-by: Raef Coles <raef.coles@arm.com>
2022-10-13 15:43:07 +01:00