Commit graph

27928 commits

Author SHA1 Message Date
Gilles Peskine
21bff21575 Support running unit tests from another directory
When running a test suite, try to change to the directory containing the
executable. This allows running a test suite from any directory, and still
allow it to access its .datax file as well as data files (generally in
tests/data_files) used by individual test cases.

Only implemented on Unix-like systems and on Windows.

Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2023-10-05 17:19:14 +02:00
Dave Rodgman
2eab462a8c Fix IAR warnings
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-05 13:30:37 +01:00
Dave Rodgman
bc2d2179be Update baremetal config to exclude MBEDTLS_SHAxxx_USE_A64_CRYPTO_IF_PRESENT
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-05 11:38:18 +01:00
Dave Rodgman
9a36f4cb97 Fix cast errors on IAR
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-05 11:25:52 +01:00
Dave Rodgman
790370b392 code style
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-05 11:02:23 +01:00
Dave Rodgman
3ba9ce3c1d Warn if using runtime detection and no Neon
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-05 09:58:33 +01:00
Dave Rodgman
cd65400c48 Add tests for runtime detection
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-05 09:40:07 +01:00
Dave Rodgman
7ed619d3fa Enable run-time detection for Thumb and Arm
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-05 09:39:56 +01:00
Dave Rodgman
bfe6021e85 Improve docs
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-05 08:31:22 +01:00
Dave Rodgman
ca92f50e12 Update docs for MBEDTLS_SHA256_USE_A64_CRYPTO_IF_PRESENT
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-05 08:24:55 +01:00
Dave Rodgman
9bf752c45d Support MSVS with clang
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-05 08:20:44 +01:00
Minos Galanakis
4855fdf887 Revert "Auto-generated files for v3.5.0"
This reverts commit 591416f32b.

Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-05 00:17:21 +01:00
Dave Rodgman
9ed1853093 require clang 4 for testing
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-05 00:06:47 +01:00
Paul Elliott
644fd34657
Merge pull request #8284 from gilles-peskine-arm/cmake-fix-3rdparty-custom-config
CMake: fix build with 3rdparty module enabled through a custom config
2023-10-04 22:59:58 +00:00
minosgalanakis
1ec69067fa
Merge pull request #1090 from Mbed-TLS/mbedtls-3.5.0rc0-pr
Mbedtls 3.5.0rc0 pr DO NOT MERGE
2023-10-04 23:47:01 +01:00
Dave Rodgman
749f2227c6 Get MBEDTLS_MAYBE_UNUSED to cover more compilers
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 22:12:33 +01:00
Minos Galanakis
f7e81d97de Updated BRANCHES.MD
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-04 21:10:40 +01:00
Dave Rodgman
5d323bf0e3 Re-assemble changelog to add missing item, plus a couple of typo fixes.
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 18:46:47 +01:00
Dave Rodgman
04d0d06e83 Code style
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 18:05:08 +01:00
Dave Rodgman
d30728cf5e Add Changelog
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 18:04:39 +01:00
Dave Rodgman
8690859097 Improve docs
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 17:40:25 +01:00
Dave Rodgman
ebe4292a9c Improve behaviour on gcc targetting arm or thumb
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 17:36:44 +01:00
Dave Rodgman
793e264fbb Fix indentation
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 17:36:20 +01:00
Dave Rodgman
d9e8083d26 Add tests for SHA256 on ARMCE for thumb, arm and aarch64
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 17:17:46 +01:00
Minos Galanakis
e35e387ad7 Bump library so-crypto, so-x509, so-tls versions.
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-04 16:17:46 +01:00
Minos Galanakis
8f4c19a680 Merge pull request #8273 from davidhorstmann-arm:target-prefix-3rdparty
Add MBEDTLS_TARGET_PREFIX to 3rdparty CMake
2023-10-04 16:03:22 +01:00
Minos Galanakis
2546d7da5c Merge pull request #8284 from gilles-peskine-arm:cmake-fix-3rdparty-custom-config
CMake: fix build with 3rdparty module enabled through a custom config
2023-10-04 16:03:21 +01:00
Dave Rodgman
feadcaf4a6 Support MBEDTLS_MAYBE_UNUSED in MSVC and IAR
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 15:27:33 +01:00
Dave Rodgman
18ddf61a75 Use MBEDTLS_MAYBE_UNUSED to simplify aes.c and let compiler remove unused variables
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 14:03:12 +01:00
Dave Rodgman
1ec1a0f0cc Introduce MBEDTLS_MAYBE_UNUSED
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 13:50:54 +01:00
Dave Rodgman
a7127eb67c tidy up
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 13:38:41 +01:00
Dave Rodgman
7a8a2490e5 Tidy-up
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 13:14:20 +01:00
Dave Rodgman
b1107aeee1 Tidy up bash syntax
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 12:30:23 +01:00
Dave Rodgman
54ada8bae8 Improve docs
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 11:55:25 +01:00
Dave Rodgman
28e38d8e12 Use lower-case for local variables
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-04 11:50:30 +01:00
Gilles Peskine
35b49c4d7d Ignore tests of built-in interfaces for driver-only testing parity
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2023-10-04 12:28:41 +02:00
Gilles Peskine
010f035cdf Renaming all MBEDTLS_HAVE for curves to MBEDTLS_ECP_HAVE
Fix test cases that were merged concurrently to
db6b4db7a0.

Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2023-10-04 12:27:14 +02:00
Minos Galanakis
591416f32b Auto-generated files for v3.5.0
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-04 00:55:02 +01:00
Minos Galanakis
974388f706 ChangeLog: Set release date
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-03 22:08:53 +01:00
Minos Galanakis
80a8156314 Prepare ChangeLog for 3.5.0 release
```
./scripts/assemble_changelog.py
```

Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-03 22:08:39 +01:00
Minos Galanakis
31ca313efa Bump version to 3.5.0
```
./scripts/bump_version.sh --version 3.5.0
```

Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-03 22:02:18 +01:00
Minos Galanakis
1a3ad265cc Merge branch 'development-restricted' into mbedtls-3.5.0rc0-pr
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-03 21:57:51 +01:00
Dave Rodgman
3406564b01
Merge pull request #8291 from minosgalanakis/bugfix/updated_check_generated_files 2023-10-03 21:18:57 +01:00
Dave Rodgman
cc5bf4946f Make SHA256 depend on Armv8, not aarch64
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-03 18:02:56 +01:00
Dave Rodgman
5ed7b2dec2 Introduce MBEDTLS_ARCH_IS_ARMV8
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-03 18:02:31 +01:00
Dave Rodgman
3cde6a2be2 Improve naming
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-03 16:02:56 +01:00
Dave Rodgman
4243610c15 Use make to generate the test command
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-10-03 15:47:05 +01:00
Dave Rodgman
3fb93a8223
Merge pull request #8295 from minosgalanakis/changelog/renamed_psa_crypto_driver_wrappers
Changelog: Added entry for psa_crypto_driver_wrappers rename
2023-10-03 14:05:56 +01:00
Dave Rodgman
130938a804
Merge pull request #1088 from gilles-peskine-arm/tls13_read_public_xxdhe_share-overflow
Fix buffer overflow in TLS 1.3 and USE_PSA_CRYPTO ClientHello ECDH/FFDH parsers
2023-10-03 12:28:38 +01:00
Minos Galanakis
3974b17631 check-generated-files: Added psa_crypto_driver_wrappers_no_static.c file
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-03 11:47:03 +01:00