1
0
mirror of https://github.com/ARMmbed/mbedtls.git synced 2025-05-16 19:57:57 +08:00

33040 Commits

Author SHA1 Message Date
Waleed Elmelegy
f162249e87 Add a comment to elaborate using split_send_frag in handshake defragmentation tests
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com>
2025-02-24 09:16:06 +00:00
Waleed Elmelegy
61b8e2d225 Enforce client authentication in handshake fragmentation tests
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com>
2025-02-24 09:16:06 +00:00
Waleed Elmelegy
39d83dd38d Remove unneeded mtu option from handshake fragmentation tests
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com>
2025-02-24 09:16:06 +00:00
Waleed Elmelegy
48874b3aba Add client authentication to handshake defragmentation tests
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com>
2025-02-24 09:16:06 +00:00
Waleed Elmelegy
f9120311e3 Require openssl to support TLS 1.3 in handshake defragmentation tests
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com>
2025-02-24 09:16:06 +00:00
Waleed Elmelegy
fccd014c2d Remove unnecessary string check in handshake defragmentation tests
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com>
2025-02-24 09:16:06 +00:00
Waleed Elmelegy
c0118d87b9 Fix typo in TLS Handshake defrafmentation tests
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com>
2025-02-24 09:16:06 +00:00
Waleed Elmelegy
0e0d5d4dc8 Improve TLS handshake defragmentation tests
* Add tests for the server side.
* Remove restriction for TLS 1.2 so that we can test TLS 1.2 & 1.3.
* Use latest version of openSSL to make sure -max_send_frag &
  -split_send_frag flags are supported.

Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com>
2025-02-24 09:16:06 +00:00
Waleed Elmelegy
79a8ded315 Add TLS Hanshake defragmentation tests
Tests uses openssl s_server with a mix of max_send_frag
and split_send_frag options.

Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com>
2025-02-24 09:16:06 +00:00
Manuel Pégourié-Gonnard
28f8e205eb
Merge pull request #9872 from rojer/tls_hs_defrag_in
Defragment incoming TLS handshake messages
2025-02-24 09:28:11 +01:00
Ronald Cron
ede8494d73
Merge pull request #9986 from valeriosetti/issue9971-development
[development] Move benchmark program to TF-PSA-Crypto
2025-02-21 14:26:49 +00:00
Valerio Setti
aa380c4a82 tf-psa-crypto: update reference
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-21 11:31:33 +01:00
Valerio Setti
69d0781576 scripts: move ecc-heap.sh to tf-psa-crypto
Since benchmark programs was moved to tf-psa-crypto, this script should
be moved as well.

Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-21 11:21:40 +01:00
Valerio Setti
f8244d49b0 programs: update .gitignore
Remove entry for benchmark program since it was moved to the tf-psa-crypto
repo.

Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-21 11:20:47 +01:00
Valerio Setti
34b4aa1f58 programs: move benchmark to tf-psa-crypto repo
This commit also removes references from Makefile and README.md.

Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-21 11:20:47 +01:00
Stefan Gloor
b5c079b13c fix: rename BEFORE_COLON and BC to avoid conflicts
Namespace BEFORE_COLON and BC defines by prepending MBEDTLS_
and expanding BC to BEFORE_COLON_STR. This is to avoid naming
conflicts with third-party code. No functional change.

Signed-off-by: Stefan Gloor <stefan.gloor@siemens.com>
2025-02-21 10:33:51 +01:00
Stefan Gloor
6a9cf11361 fix: remove superfluous BEFORE_COLON in x509_crl.c
BEFORE_COLON and BC defines with the accompanying comment are only
required in x509_crt and x509_csr, but not used in x509_crl.c.

Signed-off-by: Stefan Gloor <stefan.gloor@siemens.com>
2025-02-21 10:32:36 +01:00
Ronald Cron
dc882a8f89
Merge pull request #9939 from Harry-Ramsey/move-programs-from-mbedtls-to-framework
Move programs from mbedtls to framework
2025-02-21 07:13:17 +00:00
Harry Ramsey
5befe36d2a Update TF-PSA-Crypto pointer
Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-20 17:33:45 +00:00
Harry Ramsey
48d1374a2c Update framework pointer
Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-20 17:33:41 +00:00
Harry Ramsey
21506fd7f1 Update documentation regarding metatest
This commit updates the paths in the documentation for metatest.c as it
has been moved to MbedTLS Framework.

Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-19 15:30:25 +00:00
Harry Ramsey
f6fb2f0cb4 Update documentation regarding test_zeroize
This commit updates the paths in documentation for test_zeroize since
it has been moved to MbedTLS Framework.

Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-19 15:30:25 +00:00
Harry Ramsey
9b4035cc9e Update path for moved test_zeroize.gdb script
This commit updates the path for the moved test_zeroize.gdb script which
has been moved to MbedTLS-Framework.

Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-19 15:30:25 +00:00
Harry Ramsey
ec4af6c6e2 Update paths for moved programs in generate_visualc_files.pl
This commit updates the paths for moved programs in
generate_visualc_files.pl.

Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-19 15:30:25 +00:00
Harry Ramsey
d096793c3f Update paths for moved program files in components-build-system.sh
This commit updates the paths for dlopen_demo.sh in
components-build-system.sh as the file has been moved to the framework.

Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-19 15:30:25 +00:00
Harry Ramsey
53ba6ad106 Update paths for moved program files in CMakeLists
This commit fixes the paths of program files which were moved to the
MbedTLS Framework.

Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-19 15:30:24 +00:00
Harry Ramsey
c19b8e80e7 Update include paths in C files
Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-19 15:25:44 +00:00
Harry Ramsey
2543ec0608 Update paths for moved program files in makefiles
This commit updates the file paths necessary for dlopen_demo.sh,
metatest.c query_compile_time_config.c, query_config.h,
query_included_headers.c and zeroize.c.

This commit also adds a CFLAG to find header files now contained in the
framework.

Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-19 15:25:44 +00:00
Harry Ramsey
b14141dd71 Move programs out of Mbed TLS
This commit moves demo_common.sh, dlopen_demo.sh, metatest.c
query_compile_time_config.c, query_config.h, query_included_headers.c,
zeroize.c and test_zeroize.gdb from MbedTLS into the MbedTLS framework.

Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-19 15:17:32 +00:00
Ronald Cron
7ef0c60260
Merge pull request #9992 from Harry-Ramsey/move-zeroize-memset-configuration
Move zeroize memset configuration
2025-02-19 10:11:05 +00:00
Harry Ramsey
82c42190a1 Update TF-PSA-Crypto pointer
Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-19 08:04:35 +00:00
Harry Ramsey
2a75a60d34 Update path to user-config-zeroize-memset.h
This commit updates the path to user-config-zeroize-memset.h as it has
been moved to TF-PSA-Crypto.

Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-19 08:03:57 +00:00
Harry Ramsey
76e476245a Move zeroize config to TF-PSA-Crypto
This commit moves user-config-zeroize-memset.h to TF-PSA-Crypto where it
more appropriately belongs.

Signed-off-by: Harry Ramsey <harry.ramsey@arm.com>
2025-02-19 08:03:57 +00:00
Ronald Cron
39e2e4c3cb
Merge pull request #9957 from valeriosetti/issue136-development
[development] Add components-compliance.sh
2025-02-18 09:56:47 +00:00
Valerio Setti
1e781adb62 tf-psa-crypto: update reference
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-18 06:02:01 +01:00
Valerio Setti
e06f9f3eba framework: update reference
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-17 17:43:15 +01:00
Valerio Setti
24e6ecb502 tests: move components-compliance.sh to tf-psa-crypto repo
This file is cancelled from the Mbed TLS repo and copied to the
TF-PSA-Crypto one.

Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-17 17:40:08 +01:00
Deomid rojer Ryabkov
dd14c0a11e Remove in_hshdr
The first fragment of a fragmented handshake message always starts at the beginning of the buffer so there's no need to store it.

Signed-off-by: Deomid rojer Ryabkov <rojer@rojer.me>
2025-02-13 13:41:51 +03:00
Ronald Cron
03e704018a
Merge pull request #9917 from valeriosetti/issue9685
[development] Remove the DHE-RSA key exchange
2025-02-09 11:43:50 +00:00
Valerio Setti
bfc1ec15e6 tf-psa-crypto: update reference
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-07 17:48:11 +01:00
Valerio Setti
683e49e781 framework: update reference
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-07 17:47:59 +01:00
Valerio Setti
c8cac1d22f changelog: add note abot DHE-RSA removal
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-06 10:12:02 +01:00
Valerio Setti
1494a09ff7 test_suite_ssl: require GCM or ChaChaPoly in handshake_serialization()
Hanshake serialization requires that the selected ciphersuite uses
an AEAD algorithm. However, following the DHE-RSA removal, trying to
still use RSA signature might select a ciphersuite which is not using
AEAD, but CBC instead (see preference order in "ssl_ciphersuite.c").

This is especially problematic in tests scenarios where both GCM and
ChaChaPoly are disabled, so that CCM remains as the only AEAD algorithm.
Ciphersuites using RSA signature and CCM are very low on the preference
list, so very unlikely to be picked in tests. This cause a CBC one to
be selected in this case and the handshake_serialization() function
to fail.

In order to prevent failures from happening, in this commit we require
that either GCM or ChaChaPoly are enabled, so that ciphersuites using one
of these are likely to be picked.

Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-06 10:12:02 +01:00
Valerio Setti
d137f15e1b mbedtls_config.h: remove definition of MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-06 10:12:02 +01:00
Valerio Setti
f886924eec docs: remove references to DHE-RSA
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-06 10:12:01 +01:00
Valerio Setti
02ae66830e check_config.h: remove checks for DHE-RSA
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-06 10:05:58 +01:00
Valerio Setti
8438c637ee tests: remove references to DHE-RSA
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-06 10:05:58 +01:00
Valerio Setti
b7e2eccf1f ssl_ciphersuites: remove MBEDTLS_KEY_EXCHANGE_SOME_XXDH_1_2_ENABLED
This symbol is unused in the code so it can be removed.

Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-06 10:05:58 +01:00
Valerio Setti
b8621b6f9d ssl_ciphersuites: remove references to DHE-RSA key exchanges
In this commit also MBEDTLS_KEY_EXCHANGE_SOME_DHE_ENABLED is removed.
This cause some code in "ssl_ciphersuites_internal.h" and
"ssl_tls12_server.c" to became useless, so these blocks are removed
as well.

Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-06 10:05:58 +01:00
Valerio Setti
89743b5db5 ssl_tls: remove code related to DHE-RSA
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
2025-02-06 10:05:58 +01:00