18176 Commits

Author SHA1 Message Date
Dave Rodgman
555f84735a Update BRANCHES.md
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2024-01-22 16:47:55 +00:00
Dave Rodgman
f154831067 bump version
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2024-01-22 16:47:12 +00:00
Dave Rodgman
e557764cf3 Assemble changelog
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2024-01-22 16:46:41 +00:00
Paul Elliott
634748da23 Add Changelog for #8687
Signed-off-by: Paul Elliott <paul.elliott@arm.com>
2024-01-22 16:00:33 +00:00
Jonathan Winzig
e90cbc3d12 Fix Issue #8687
Signed-off-by: Jonathan Winzig <jwinzig@hilscher.com>
2024-01-22 16:00:07 +00:00
Jonathan Winzig
d78496cccf Add tests for Issue #8687
Signed-off-by: Jonathan Winzig <jwinzig@hilscher.com>
2024-01-22 16:00:07 +00:00
Janos Follath
4a606d6f3f Update Marvin fix Changelog entry
Upon further consideration we think that a remote attacker close to the
victim might be able to have precise enough timing information to
exploit the side channel as well. Update the Changelog to reflect this.

Signed-off-by: Janos Follath <janos.follath@arm.com>
2024-01-22 15:59:22 +00:00
Janos Follath
80a12f86f9 Add new internal header to visualc project
Signed-off-by: Janos Follath <janos.follath@arm.com>
2024-01-22 15:58:57 +00:00
Janos Follath
1a9a69778e Fix 'missing prototype' warnings
Signed-off-by: Janos Follath <janos.follath@arm.com>
2024-01-22 15:58:57 +00:00
Janos Follath
8cdb6064de Align Montgomery init with development
The signature and naming of the Montgomrey initialisation function in
development and in the LTS was different. Align them for easier
readability and maintenance.

Signed-off-by: Janos Follath <janos.follath@arm.com>
2024-01-22 15:58:57 +00:00
Janos Follath
f10bfbbe74 Add Changelog for the Marvin attack fix
Signed-off-by: Janos Follath <janos.follath@arm.com>
2024-01-22 15:58:57 +00:00
Janos Follath
eaeff5b75a Add warning for PKCS 1.5 decryption
Any timing variance dependant on the output of this function enables a
Bleichenbacher attack. It is extremely difficult to use safely.

In the Marvin attack paper
(https://people.redhat.com/~hkario/marvin/marvin-attack-paper.pdf) the
author suggests that implementations of PKCS 1.5 decryption that don't
include a countermeasure should be considered inherently dangerous.

They suggest that all libraries implement the same countermeasure, as
implementing different countermeasures across libraries enables the
Bleichenbacher attack as well.

This is extremely fragile and therefore we don't implement it. The use
of PKCS 1.5 in Mbed TLS implements the countermeasures recommended in
the TLS standard (7.4.7.1 of RFC 5246) and is not vulnerable.

Add a warning to PKCS 1.5 decryption to warn users about this.

Signed-off-by: Janos Follath <janos.follath@arm.com>
2024-01-22 15:58:57 +00:00
Janos Follath
601bffc4ce Extend blinding to RSA result check
Signed-off-by: Janos Follath <janos.follath@arm.com>
2024-01-22 15:58:57 +00:00
Janos Follath
aa6760d7b5 Make RSA unblinding constant flow
Signed-off-by: Janos Follath <janos.follath@arm.com>
2024-01-22 15:58:57 +00:00
Janos Follath
4fe396f1e1 Move some bignum functions to internal header
We will need a couple of low level functions to implement safe
unblinding in RSA.

Signed-off-by: Janos Follath <janos.follath@arm.com>
2024-01-22 15:58:57 +00:00
Janos Follath
42175031ca Move calculating RR into a separate function
So far we needed it only locally here, but we will need calculating RR
for safe unblinding in RSA as well.

Signed-off-by: Janos Follath <janos.follath@arm.com>
2024-01-22 15:58:57 +00:00
Dave Rodgman
3a91dad9dc Add docs re Everest license
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-11-08 11:41:55 +00:00
Dave Rodgman
68142f15fd Update BRANCHES
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-11-06 11:51:08 +00:00
Dave Rodgman
d0ac48087b Bump version
./scripts/bump_version.sh --version 2.28.6 --so-crypto 7 --so-x509 1 --so-tls 14

Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-11-03 13:02:18 +00:00
Dave Rodgman
18b3e8aed1 Assemble changelog
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-11-03 13:01:42 +00:00
Dave Rodgman
ace2ecb701 Add Changelog for license
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-11-03 12:59:34 +00:00
Dave Rodgman
f429557c59 Update documentation
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-11-03 12:59:30 +00:00
Dave Rodgman
625458b990 Update header
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-11-03 12:57:37 +00:00
Dave Rodgman
0f2971a968 Update headers
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-11-03 12:54:54 +00:00
minosgalanakis
47e8cc9db2
Merge pull request #1092 from Mbed-TLS/mbedtls-2.28.5rc0-pr
Mbedtls 2.28.5rc0 pr
2023-10-04 23:11:08 +01:00
Minos Galanakis
e18540886c Updated BRANCHES.md
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-04 21:05:17 +01:00
Minos Galanakis
468d6e8e0e ChangeLog: Set release date
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-03 22:28:07 +01:00
Minos Galanakis
7de3eed636 Prepare ChangeLog for 2.28.5 release
```
./scripts/assemble_changelog.py
```

Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-03 22:26:03 +01:00
Minos Galanakis
c7a8ea998d Bump version to 2.28.5
```
./scripts/bump_version.sh --version 2.28.5
```

Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-03 22:24:04 +01:00
Minos Galanakis
6d169947e9 Merge branch 'mbedtls-2.28-restricted' into mbedtls-2.28.5rc0-pr
Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
2023-10-03 22:22:36 +01:00
Dave Rodgman
da635ab657
Merge pull request #8280 from gilles-peskine-arm/ssl_cache-negative_errors-2.28
Backport 2.28: ssl_cache: misc improvements
2023-09-29 17:58:10 +00:00
Dave Rodgman
8c28032537
Merge pull request #8279 from gilles-peskine-arm/mbedtls_ecdsa_can_do
Backport 2.28: Bug Fix: mbedtls_ecdsa_verify_restartable fails with ECDSA_SIGN_ALT
2023-09-29 13:11:43 +00:00
Gilles Peskine
5856fd32dd Changelog entry for mbedtls_ssl_cache error code fixes
Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2023-09-29 13:42:47 +02:00
Gilles Peskine
fe4d93ad4d ssl_cache: return error codes on error
mbedtls_ssl_cache_get() and mbedtls_ssl_cache_set() returned 1 on many error
conditions. Change this to returning a negative MBEDTLS_ERR_xxx error code.

Completeness: after this commit, there are no longer any occurrences of
`return 1` or `ret = 1`.

Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2023-09-29 13:40:33 +02:00
Gilles Peskine
917dd8bd81 Add new error code for SSL cache entry not found
There was no good error to return in this case.

Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
2023-09-29 13:39:49 +02:00
JonathanWitthoeft
3ead877b68 Adjust ChangeLog
Signed-off-by: JonathanWitthoeft <jonw@gridconnect.com>
2023-09-29 13:31:49 +02:00
JonathanWitthoeft
930679a1d7 Make mbedtls_ecdsa_can_do definition unconditional
Signed-off-by: JonathanWitthoeft <jonw@gridconnect.com>
2023-09-29 13:31:48 +02:00
JonathanWitthoeft
bfb0b39460 Bug Fix: mbedtls_ecdsa_verify_restartable fails with ECDSA_SIGN_ALT
When ECDSA_SIGN_ALT but not ECDSA_VERIFY_ALT, mbedtls_ecdsa_can_do was not being defined causing mbedtls_ecdsa_verify_restartable to always fail

Signed-off-by: JonathanWitthoeft <jonw@gridconnect.com>
2023-09-29 13:31:47 +02:00
Dave Rodgman
ba1d63e36f
Merge pull request #1085 from daverodgman/update-ct-changelog-2.28
Backport 2.28: Update padding const-time fix changelog
2023-09-28 11:34:03 +01:00
Dave Rodgman
0ea272d110 Update padding const-time fix changelog
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
2023-09-27 16:31:33 +01:00
Dave Rodgman
dce82cd914
Merge pull request #8254 from paul-elliott-arm/fix_travis_coverity_build_2_28
[Backport 2.28] Re-add python install of requirements to Travis CI.
2023-09-26 16:56:17 +00:00
Dave Rodgman
7a8ec0f56c
Merge pull request #8209 from lpy4105/issue/8168/2.28_fix-aesni-selection
2.28: Fix AESNI selection
2023-09-26 16:55:28 +00:00
Paul Elliott
13481f0439 Re-add python install of requirements to Travis CI.
Also correct 'distro to 'dist' and update ubuntu to jammy and python
to 3.10 to hopefully fend off future issues. Too much got removed
when disabling travis and the Coverity scan build was failing on 'make
generated-files', due to lack of installed python dependencies

Signed-off-by: Paul Elliott <paul.elliott@arm.com>
2023-09-26 16:04:44 +01:00
Pengyu Lv
8068b0835b Fix comment
Signed-off-by: Pengyu Lv <pengyu.lv@arm.com>
2023-09-26 09:27:04 +08:00
Gilles Peskine
9fe480a5f6
Merge pull request #1081 from waleed-elmelegy-arm/backport_check-set_padding-is-called
Backport 2.28: Check set_padding has been called in mbedtls_cipher_finish
2023-09-25 17:12:41 +02:00
Waleed Elmelegy
916ed7b8db restore internal comment in cipher.h due to LTS
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com>
2023-09-25 15:18:48 +01:00
Waleed Elmelegy
8ce42ebd87 Remove invalid comments from cipher.h
Signed-off-by: Waleed Elmelegy <waleed.elmelegy@arm.com>
2023-09-25 14:21:49 +01:00
Manuel Pégourié-Gonnard
e4138e3279 Fix a typo
Signed-off-by: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com>
2023-09-25 14:13:24 +01:00
Manuel Pégourié-Gonnard
8013e685f5 Clarify calling sequence in the Cipher layer
Signed-off-by: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com>
2023-09-25 14:12:08 +01:00
Manuel Pégourié-Gonnard
3697954ac6 Fix inconsistent documentation of cipher_setup()
- the \internal note said that calling cipher_init() first would be made
mandatory later, but the documention of the ctx parameter already said
the context had to be initialized...
- the documentation was using the word initialize for two different
meanings (calling setup() vs calling init()), making the documentation
of the ctx parameter quite confusing (you must initialize before you can
initialize...)

Signed-off-by: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com>
2023-09-25 14:10:49 +01:00