Valerio Setti
287f6d1f5c
all.sh: unset MBEDTLS symbols for modes/keys only when !PSA_CRYPTO_CONFIG
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:13:33 +02:00
Valerio Setti
862021a118
all.sh: improve comments in common_test_full_no_cipher_with_psa_crypto
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:13:33 +02:00
Valerio Setti
5b4039f36d
all.sh: rename common config/test function
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:13:33 +02:00
Valerio Setti
4529d65e30
all.sh: improve test_full_no_cipher()
...
- remove unnecessary disabled items (most of them were already
disabled automatically once MBEDTLS_SSL_TLS_C was disabled)
- improve dependencies' comments, especially the last one which
list items depending on PSA_CRYPTO_C
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:13:33 +02:00
Valerio Setti
fb0b0ffaa4
all.sh: keep symbols that don't depend on CIPHER_C (directly or indirectly)
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:13:33 +02:00
Valerio Setti
c84d940704
all.sh: fix comments in common_test_full_no_cipher_with_crypto()
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:13:33 +02:00
Valerio Setti
df17a102e5
all.sh: replace minus sign in text messages with "no"
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:13:33 +02:00
Valerio Setti
36fe8b9f4b
psa_crypto_cipher: add guard for unused variable
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:13:33 +02:00
Valerio Setti
1e21f26d88
psa_crypto_cipher: add helper to validate PSA cipher values
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:13:33 +02:00
Valerio Setti
7e710e8272
all.sh: add components as full_no_cipher with CRYPTO_C and CRYPTO_CONFIG
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:12:06 +02:00
Valerio Setti
4a249828a8
psa_crypto_cipher: add mbedtls_cipher_values_from_psa()
...
This commit splits mbedtls_cipher_info_from_psa() in 2 parts:
- mbedtls_cipher_values_from_psa() that performs parameters' validation and
return cipher's values
- mbedtls_cipher_info_from_psa() which then use those values to return
the proper cipher_info pointer. Of course this depends on CIPHER_C.
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:12:06 +02:00
Valerio Setti
2c2adedd82
psa_crypto_aead: add guard for CIPHER_C dependency
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:12:06 +02:00
Valerio Setti
c5d9dd262b
adjust_psa_from_legacy: enable ALG_STREAM_CIPHER on when CIPHER_C is defined
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:12:06 +02:00
Valerio Setti
c1d50b6314
check_config: fix dependency of PSA_CRYPTO_C on CIPHER_C
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-27 09:12:06 +02:00
Bence Szépkúti
51328162e6
Merge pull request #8374 from sergio-nsk/sergio-nsk/8372/2
...
Fix compiling AESNI in Mbed-TLS with clang on Windows
2023-10-26 21:21:01 +00:00
Dave Rodgman
2db1e354e3
Merge pull request #8408 from daverodgman/iar-fix-aes
...
Fix MBEDTLS_MAYBE_UNUSED for IAR
2023-10-26 15:53:11 +00:00
Gilles Peskine
b3d0ed2e6e
Merge pull request #8303 from valeriosetti/issue6316
...
Add test component with all ciphers and AEADs accelerated only
2023-10-26 15:53:10 +00:00
Gilles Peskine
e960ddd3df
Merge pull request #8306 from yanesca/psa_threads_design
...
Add the PSA threading design to the documentation
2023-10-26 15:53:10 +00:00
Gilles Peskine
4f144093ba
Merge pull request #8294 from gilles-peskine-arm/test-datax-chdir
...
Support running unit tests from another directory
2023-10-26 15:53:10 +00:00
Tom Cosgrove
257f6dd57d
Fix builds in conda-forge, which doesn't have CLOCK_BOOTTIME
...
Fixes #8422
Signed-off-by: Tom Cosgrove <tom.cosgrove@arm.com>
2023-10-26 14:04:34 +01:00
Janos Follath
a365efc6f1
Threading design: fix internal links
...
Signed-off-by: Janos Follath <janos.follath@arm.com>
2023-10-26 10:22:55 +01:00
Ronald Cron
95b735530c
Merge pull request #6719 from yuhaoth/pr/tls13-early-data-add-early-data-of-client-hello
...
TLS 1.3: EarlyData SRV: Add early data extension parser.
2023-10-26 08:31:53 +00:00
Gilles Peskine
5d055f8206
Merge pull request #7844 from mpg/ssl-progs-usage
...
Fix usage & error reporting in SSL programs
2023-10-26 08:19:25 +00:00
Valerio Setti
507e08f9af
analyze_outcomes: update cipher/aead data
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-26 10:05:01 +02:00
Valerio Setti
bbc46b4cc2
cipher: improve code readibility in mbedtls_cipher_setup()
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-26 09:00:21 +02:00
Gilles Peskine
cc2bbfe905
Fix invocation with explicit .datax file
...
Don't chdir when invoking a test suite executable with an explicit .datax
file. The point of the chdir is to automatically find the .datax file (and
the relative location of the data_files directory) in typical cases. This
conflicts with the expectation that passing a relative path to a .datax file
will work.
(This is what I had originally intended, and what is documented in the
comment, but I forgot to add the argc check in the initial commit.)
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2023-10-25 17:45:50 +02:00
Gilles Peskine
bf3c3fa122
Define try_chdir everywhere
...
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2023-10-25 17:43:10 +02:00
Dave Rodgman
d1c4fb07ee
Support older IAR versions
...
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-25 15:07:35 +01:00
Valerio Setti
ad8b7f0306
all.sh: accelerate ALG_[STREAM_CIPHER/ECB_NO_PADDING] in accel_cipher_aead()
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:39:50 +02:00
Valerio Setti
97454fde54
all.sh: accelerate CMAC in test_psa_crypto_config_accel_cipher_aead()
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:27:12 +02:00
Valerio Setti
3b1559060a
test_suite_psa_crypto: replace builtin dependencies with PSA_WANT
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Valerio Setti
9d9b4b547f
test_suite_cipher: use TEST_ASSUME() to evaluate supported ciphers
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Valerio Setti
5cd18f9150
analyze_oucomes.py: ignore line-too-long error for skipped tests
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Valerio Setti
b680fc4f0b
all.sh: add a common configuration function for accel/reference components
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Valerio Setti
93941440c1
all.sh: keep PKCS5/12 enabled in the reference component
...
This commit also add proper "ignore" fields to the "analyze_outcomes.py"
script.
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Valerio Setti
29bcd01cf3
all.sh: move [accel/reference]_cipher_aead to crypto_full
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Valerio Setti
79a02de79f
cipher: check that ctx_alloc_func is not NULL before calling it
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Valerio Setti
a6c0761c43
cipher_wrap: fix guards for GCM/CCM AES
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Valerio Setti
e86677d0c3
pkparse: fix missing guards for pkcs5/12 functions
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Valerio Setti
58d2b1aff2
all.sh: fix minor issues
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Valerio Setti
7448cee8f0
analyze_outcomes.py: skip tests that depends on builtin features
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Valerio Setti
d3bdccc063
test_suite_cipher: successfully quit test if no cipher is supported
...
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Valerio Setti
b6b301fa8d
test: add component accelerating both ciphers and AEADs
...
This also adds a new task in analyze_outcomes.py for checking
the accelaration coverage against the reference element.
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2023-10-25 12:03:36 +02:00
Dave Rodgman
d69d3cda34
Merge pull request #8298 from daverodgman/sha-armce-thumb2
...
Support SHA256 acceleration on Armv8 thumb2 and arm
2023-10-24 21:23:15 +00:00
Dave Rodgman
f842868dd9
Fix MBEDTLS_MAYBE_UNUSED for IAR
...
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-24 14:18:38 +01:00
Manuel Pégourié-Gonnard
a675ef8537
Merge pull request #8368 from valeriosetti/issue8315
...
Clarify driver handling of ALG_STREAM and ALG_ECB
2023-10-24 07:32:12 +00:00
Thomas Daubney
c0ae569066
Make lcov.sh run from the build directory
...
lcov.sh can now be called from any build directory and
also still works with in-place builds too.
Signed-off-by: Thomas Daubney <thomas.daubney@arm.com>
2023-10-23 17:25:52 +01:00
Dave Rodgman
514590210b
Merge remote-tracking branch 'origin/development' into sha-armce-thumb2
...
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-23 15:35:07 +01:00
Paul Elliott
6c68df4155
Convert interruptible test over to using TEST_CALLOC
...
Also fix potential leak in unlikely edge case.
Signed-off-by: Paul Elliott <paul.elliott@arm.com>
2023-10-23 15:33:37 +01:00
Dave Rodgman
66d5512571
Remove dependency on asm/hwcap.h
...
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-23 15:12:32 +01:00