Gilles Peskine
ef96fc616e
Merge pull request #10053 from gilles-peskine-arm/doc-threading-needed-by-psa-2.28
...
Backport 2.28: Document PSA's need for threading
2025-03-13 15:42:52 +00:00
Bence Szépkúti
85cb1f5fad
Merge pull request #10044 from Mbed-TLS/msvc-format-size-macros-2.28
...
[Backport 2.28] Fix preprocessor guards for C99 format size specifiers
2025-03-13 10:09:18 +00:00
Gilles Peskine
23981ad57f
Merge pull request #10026 from waleed-elmelegy-arm/mbedtls-2.28-fix-key-deriv-bad-state-error
...
Backport 2.28: Fix psa_key_derivation_input_bytes() not detecting bad state
2025-03-13 09:31:07 +00:00
Bence Szépkúti
cb094f9192
Use an array of strings instead of pointer smuggling
...
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2025-03-12 19:16:47 +01:00
Bence Szépkúti
cfadd96a9b
Clarify changelog
...
Remove mention of the shipped .sln files, as those are planned to be
removed from Mbed TLS.
Clarify the affected CRT headers.
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2025-03-12 17:32:23 +01:00
Gilles Peskine
012ebb01f9
Document PSA's need for threading
...
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com >
2025-03-11 15:04:05 +01:00
Waleed Elmelegy
254cadac70
Replace zero by PSA_ALG_NONE in key derivation internal functions
...
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com >
2025-03-11 12:27:34 +00:00
Bence Szépkúti
af07ab897c
Fix comments
...
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2025-03-08 01:02:37 +01:00
Bence Szépkúti
ded35000b0
Update changelog to call out MinGW
...
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2025-03-08 00:40:47 +01:00
Bence Szépkúti
b4f25121cc
Never use %zu on MinGW
...
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2025-03-08 00:23:37 +01:00
Bence Szépkúti
85167e041c
Remove Everest VS2010 compatibility headers
...
These headers were necessary for compatibility with Visual Studio 2010,
and interfere with the system headers on Visual Studio 2013+, eg. when
building Mbed TLS using the .sln file shipped with the project.
Move the still-required definition of "inline" to callconv.h, where the
definition for GCC also lives.
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2025-03-08 00:23:37 +01:00
Bence Szépkúti
e7ee902e09
Fix MSVC version guard for C99 format size specifiers
...
Visual Studio 2013 (_MSC_VER == 1800) doesn't support %zu - only use it
on 2015 and above (_MSC_VER >= 1900).
%ldd works on Visual Studio 2013, but this patch keeps the two macro
definitions together, for simplicity's sake.
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2025-03-08 00:23:37 +01:00
Bence Szépkúti
5d554667c4
Disable fatal assertions in Windows printf tests
...
The Windows CRT treats any invalid format specifiers passed to the CRT
as fatal assertion failures. Disable thie behaviour temporarily while
testing if the format specifiers we use are supported.
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2025-03-08 00:23:35 +01:00
Bence Szépkúti
94b0eea23f
Test handling of format macros defined in debug.h
...
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2025-03-07 17:59:00 +01:00
Bence Szépkúti
27da54de49
Run test_suite_debug without MBEDTLS_SSL_TLS_C
...
Move the suite's global dependency on MBEDTLS_SSL_TLS_C to the
individual test cases.
Add an preprocesor guard around string_debug to prevent warning about unused
functions.
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2025-03-07 17:58:58 +01:00
Waleed Elmelegy
e014887ea5
Fix code style for key derivation input function
...
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com >
2025-03-03 15:01:38 +00:00
Waleed Elmelegy
3dee9a92e4
Replace zero by PSA_ALG_NONE in key derivation test function
...
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com >
2025-03-03 13:13:17 +00:00
Waleed Elmelegy
76bafb6a33
Replace zero by PSA_ALG_NONE in key derivation testing
...
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com >
2025-03-03 13:12:36 +00:00
Waleed Elmelegy
fd01e44cbe
Simplify testing psa_key_derivation_input_*() bad state
...
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com >
2025-03-03 13:11:26 +00:00
Waleed Elmelegy
c8c89eda5d
Fix psa_key_derivation_input_integer() not detecting bad state
...
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com >
2025-03-03 13:04:12 +00:00
Janos Follath
2153b1bc03
Merge pull request #9920 from davidhorstmann-arm/clarify-x509-security-md-2.28
...
[Backport 2.28] Add X.509 formatting validation to SECURITY.md
2025-02-20 14:41:37 +00:00
Janos Follath
0834c59d06
Merge pull request #9496 from minosgalanakis/doc/add_mbedtls_ecp_check_privkey_comment_bp28
...
[Backport 2.28] Refactored a minor check in ecp check privkey
2025-01-24 09:44:31 +00:00
Minos Galanakis
49d440372f
tf-psa-crypto/drivers/builtin/src/ecp.c
...
Update tf-psa-crypto/drivers/builtin/src/ecp.c
Co-authored-by: Gilles Peskine <gilles.peskine@arm.com >
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com >
2025-01-23 15:29:58 +00:00
David Horstmann
09d0b71d2b
Fix missing-word typo
...
Signed-off-by: David Horstmann <david.horstmann@arm.com >
2025-01-23 10:28:59 +00:00
David Horstmann
2c400fc1a2
Add paragraph on undefined behaviour
...
Add a note that we do aim to protect against undefined behaviour and
undefined behaviour in certificate parsing is in scope.
Signed-off-by: David Horstmann <david.horstmann@arm.com >
2025-01-22 14:50:36 +00:00
David Horstmann
110e5341eb
Add X.509 formatting validation to SECURITY.md
...
Clarify that strict formatting of X.509 certificates is not checked by
Mbed TLS and that it therefore should not be used to construct a CA.
Signed-off-by: David Horstmann <david.horstmann@arm.com >
2025-01-22 14:34:09 +00:00
Paul Elliott
32fe8f3cf1
Merge pull request #9849 from solardiz/mbedtls-2.28
...
[Backport 2.28] Specify previously missed register clobbers in AES-NI asm blocks
2024-12-13 15:25:50 +00:00
Solar Designer
1cd6fb57f9
Add change log entry on AES-NI asm block fixes
...
Co-authored-by: Gilles Peskine <gilles.peskine@arm.com >
Signed-off-by: Solar Designer <solar@openwall.com >
2024-12-13 02:15:55 +01:00
Solar Designer
4ad27aa47e
Specify previously missed XMM register clobbers in AES-NI asm blocks
...
Noticed by Gilles Peskine
Co-authored-by: Gilles Peskine <gilles.peskine@arm.com >
Signed-off-by: Solar Designer <solar@openwall.com >
2024-12-13 02:14:13 +01:00
Solar Designer
4115440aa7
Specify register clobbers in mbedtls_aesni_crypt_ecb()
...
Signed-off-by: Solar Designer <solar@openwall.com >
2024-12-13 02:13:03 +01:00
Gilles Peskine
9b1ec06287
Merge pull request #9821 from gilles-peskine-arm/psa-storage-test-cases-never-supported-2.28-fix-copypasta
...
Backport 2.28: Make some edge cases of not-supported or invalid mechanisms more uniform
2024-12-11 19:06:42 +00:00
Janos Follath
7198389aab
Merge pull request #9811 from SuperIlu/mbedtls-2.28
...
Mbedtls 2.28: Fix compilation on MS-DOS DJGPP
2024-12-03 09:12:03 +00:00
Gilles Peskine
e681a4e7e5
Fix copypasta
...
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com >
2024-12-02 21:40:21 +01:00
SuperIlu
97268b836e
reworked changelog according to suggestion
...
Signed-off-by: SuperIlu <superilu@yahoo.com >
2024-12-02 21:25:54 +01:00
SuperIlu
4b8fbf6eed
Added changelog
...
Signed-off-by: SuperIlu <superilu@yahoo.com >
2024-12-01 10:32:50 +01:00
SuperIlu
6d327128b5
Make mbedTLS compile with MS-DOS DJGPP
...
Signed-off-by: SuperIlu <superilu@yahoo.com >
2024-12-01 10:32:46 +01:00
David Horstmann
763c116a66
Merge pull request #9774 from Harry-Ramsey/update-gcm-doc-2.28
...
[Backport 2.28] Fix doc on GCM API
2024-11-21 17:35:56 +00:00
Harry Ramsey
c22ead77a8
Fix documentation for GCM decryption functions
...
This commit fixes documentation specifying buffer overlap on GCM
decryption functions.
Signed-off-by: Harry Ramsey <harry.ramsey@arm.com >
2024-11-13 19:22:51 +00:00
Harry Ramsey
9d99e98503
Remove trailing whitespace
...
This commit removes trailing whitespace in test_suite_gcm.function.
Signed-off-by: Harry Ramsey <harry.ramsey@arm.com >
2024-11-13 15:57:29 +00:00
Harry Ramsey
a1abbdb2b3
Add new line to end of test case files
...
This commit adds a new line to the end of test case files to pass
check_files.
Signed-off-by: Harry Ramsey <harry.ramsey@arm.com >
2024-11-13 12:49:34 +00:00
Harry Ramsey
0cd29510f6
Add test cases for AES GCM input and output buffer overlap
...
This commit adds test cases for input and output buffer overlap. The
data for the test cases is a duplicate of existing encrypt/decrypt test
cases.
The two test functions gcm_<encrypt/decrypt>_input_output_buffer_overlap
are modified to use a single malloc buffer rounded to the nearest
128-bits/16-bytes for input and output.
Signed-off-by: Harry Ramsey <harry.ramsey@arm.com >
2024-11-13 11:23:57 +00:00
Harry Ramsey
7220652204
Update GCM buffer overlap documentation
...
This commit updates GCM buffer overlap documentation to explicitly
support overlapping encryption/decryption buffers for GCM.
Signed-off-by: Harry Ramsey <harry.ramsey@arm.com >
2024-11-13 10:38:41 +00:00
Paul Elliott
89c68e206b
Merge pull request #9736 from mpg/drop-armcc5-2.28
...
[2.28] Drop armcc5 support in all.sh
2024-10-30 12:29:32 +00:00
Gilles Peskine
89a87b5353
Merge pull request #9729 from paul-elliott-arm/fix_new_coverity_issues_2.28
...
[Backport 2.28] Fix new coverity issues
2024-10-29 14:58:39 +00:00
Bence Szépkúti
0f2c45a78a
Merge pull request #9734 from bensze01/graviton-testing-2.28
...
[Backport 2.28] Add default config tests for the A64, A32, Thumb 1 and Thumb 2 instruction sets
2024-10-29 12:24:56 +00:00
Manuel Pégourié-Gonnard
a674e988c9
Drop building with armcc5 in all.sh
...
Signed-off-by: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com >
2024-10-29 11:52:49 +01:00
Bence Szépkúti
61da0ddb07
Add override arguments for new gcc targets
...
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2024-10-28 13:33:48 +01:00
Bence Szépkúti
b14dd763c3
Clarify GCC version requirement
...
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2024-10-28 13:33:09 +01:00
Bence Szépkúti
478730eed2
Split up the Thumb-1 test component
...
The Thumb-1 tests are by far the slowest, so split the -O0 and -Os tests
into their own components.
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2024-10-28 13:32:41 +01:00
Bence Szépkúti
73d8640bd3
Remove superfluous invocations of make clean
...
Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com >
2024-10-28 13:31:55 +01:00