Commit Graph

6485 Commits

Author SHA1 Message Date
Ron Eldor
0557b8f888 Move definition to cipher.h
Define `MBEDTLS_CIPHER_MODE_STREAM` for `MBEDTLS_CIPHER_NULL_CIPHER`
as well, in cipher.h. Remove redundant definition in `cipher_internal.h`
2018-06-28 08:46:23 +03:00
Ron Eldor
22bc7c17bb Add entry in ChangeLog
Add entry in ChangeLog for compilation error fix of #1719
2018-06-28 08:46:12 +03:00
Ron Eldor
8c02dd1709 Move definition of MBEDTLS_CIPHER_MODE_STREAM
Move definition of `MBEDTLS_CIPHER_MODE_STREAM` to header file
(`mbedtls_cipher_internal.h`), because it is used by more than
one file. Raised by TrinityTonic in #1719
2018-06-28 08:44:47 +03:00
Ron Eldor
4624030dc4 Documentation error in mbedtls_ssl_get_session
Fix Documentation error in `mbedtls_ssl_get_session`.
This function supports deep copying of the session,
and the peer certificate is not lost anymore, Resolves #926
2018-06-27 17:49:23 +03:00
Ron Eldor
415621f2cf Update the forum link in the README file
Update the forum link in the readme file as well.
2018-06-27 14:41:40 +03:00
Ron Eldor
09208fe442 Update the Mbed TLS forum link
Update the link to the new Mbed TLS forum
2018-06-27 14:41:32 +03:00
Simon Butcher
0e342f77fc Merge remote-tracking branch 'public/pr/1390' into mbedtls-2.7 2018-06-27 11:11:34 +01:00
Simon Butcher
035d824ad5 Merge remote-tracking branch 'public/pr/1768' into mbedtls-2.7 2018-06-27 11:09:27 +01:00
Simon Butcher
c5edf81065 Merge remote-tracking branch 'public/pr/1772' into mbedtls-2.7 2018-06-27 11:08:33 +01:00
Simon Butcher
f15cfd5d04 Merge remote-tracking branch 'public/pr/1557' into mbedtls-2.7 2018-06-27 11:07:50 +01:00
Ron Eldor
5146ef3811 Adjust to new RSA infrastructure
Don't access the rsa cotext parameters directly, but use
the local `mbedtls_mpi` variable that were exported.
2018-06-27 11:55:59 +03:00
Ron Eldor
0d63e6229d Fix compilation errors after updating
Fix compilation errorsthat happened after new code introduced
by updating the branch. Replaced `exit` label with `cleanup`.
2018-06-27 08:49:00 +03:00
Ron Eldor
45486b135d Fix style issue
Add space before and after paranthesis.
2018-06-26 19:11:12 +03:00
Ron Eldor
e1440898ca Add check for return code of bignumber code
Add check for return code of `mbedtls_mpi_write_file`
as commented by @sbutcher-arm
2018-06-26 19:11:05 +03:00
Ron Eldor
9aff65afa4 remove additional zero byte when writing pub der
Remove `- 1` for setting location of output buffer,
which added a leading zero which cause failure in ASN1 parsing.
Fixes #1257
2018-06-26 17:28:07 +03:00
Ron Eldor
612a600186 Fix typo in ChangeLog
Fix typo in ChangeLog discovered in PR review
2018-06-24 17:23:29 +03:00
Ron Eldor
df9b93e768 Remove unneeded namesapcing in header files
Remove the `mbedtls` namesapcing in the `#include` in header files
Resolves issue #857
2018-06-24 17:23:16 +03:00
Simon Butcher
9a08e44972 Add a ChangeLog entry for memory leak in mbedtls_x509_csr_parse() 2018-06-22 12:02:59 +01:00
Philippe Antoine
0f91c0f441 Coding style
Commit to be squashed
2018-06-22 11:45:38 +01:00
Philippe Antoine
dc58e59280 Simplify code in mbedtls_x509_csr_parse 2018-06-22 11:44:48 +01:00
Philippe Antoine
78657e52d8 Fix memory leak in mbedtls_x509_csr_parse 2018-06-22 11:44:38 +01:00
Andres Amaya Garcia
0fc4e0878e Document ssl_write_real() behaviour in detail 2018-06-21 19:29:49 +01:00
Andres Amaya Garcia
dbd17b75f3 Allow 0 as a valid ret value for mbedtls_ssl_write
This patch modifies the documentation for mbedtls_ssl_write() to allow
0 as a valid return value as this is the correct number of bytes that
should be returned when an empty TLS Application record is sent.
2018-06-21 19:29:37 +01:00
Andres Amaya Garcia
294331a315 Add ChangeLog entry for mbedtls_ssl_write() docs 2018-06-21 19:27:44 +01:00
Jaeden Amero
88e414f4b7 Merge remote-tracking branch 'upstream-restricted/pr/488' into mbedtls-2.7 2018-06-18 15:41:22 +01:00
Simon Butcher
662ae9eaae Change the library version to 2.7.4 2018-06-18 14:42:14 +01:00
Simon Butcher
02582b2804 Add ChangeLog entry for clang version fix. Issue #1072 2018-06-18 11:56:13 +01:00
Simon Butcher
aabfe6da7b Merge remote-tracking branch 'public/pr/1647' into mbedtls-2.7 2018-06-15 13:03:50 +01:00
Simon Butcher
0623cce53e Merge remote-tracking branch 'public/pr/1664' into mbedtls-2.7 2018-06-15 13:03:22 +01:00
Simon Butcher
112dfd5bc5 Merge remote-tracking branch 'public/pr/1728' into mbedtls-2.7 2018-06-15 13:02:40 +01:00
Simon Butcher
83c7ecbf5b Merge remote-tracking branch 'public/pr/1732' into mbedtls-2.7 2018-06-15 13:00:30 +01:00
Simon Butcher
d8ea8d41a3 Add ChangeLog entry for Microblaze fix 2018-06-15 09:30:34 +01:00
Zach van Rijn
df484d6b11 Fix MicroBlaze register typo. 2018-06-15 07:39:57 +01:00
Simon Butcher
47212c8e2c Merge remote-tracking branch 'public/pr/1581' into mbedtls-2.7 2018-06-14 11:02:43 +01:00
Simon Butcher
da46a40855 Merge remote-tracking branch 'public/pr/1711' into mbedtls-2.7 2018-06-14 11:01:14 +01:00
Simon Butcher
49de6b89c1 Compilation warning fixes on 32b platfrom with IAR
Fix compilation warnings with IAR toolchain, on 32 bit platform.
Reported by rahmanih in #683

This is based on work by Ron Eldor in PR #750, some of which was independently
fixed by Azim Khan and already merged in PR #1655.
2018-06-14 09:05:55 +01:00
Simon Butcher
a96b9d46f7 Add entry for PR #1646, for IAR Compiler Warnings fix
PR #1655 is a change to the behaviour of the CMake files therefore should be
recorded in the Changelog.
2018-06-12 17:42:02 +01:00
Simon Butcher
fb6da8815c Merge remote-tracking branch 'public/pr/1655' into mbedtls-2.7 2018-06-12 17:40:08 +01:00
Simon Butcher
c26080e23f Merge remote-tracking branch 'public/pr/1670' into mbedtls-2.7 2018-06-12 17:27:19 +01:00
Simon Butcher
8c83673eb2 Merge remote-tracking branch 'public/pr/1708' into mbedtls-2.7 2018-06-12 17:26:55 +01:00
Simon Butcher
856870952a Merge remote-tracking branch 'public/pr/1709' into mbedtls-2.7 2018-06-12 17:25:19 +01:00
Darryl Green
9e867214c3 Change symlink to hardlink to avoid permission issues 2018-06-11 11:31:40 +01:00
Darryl Green
215a40631f Fix out-of-tree testing symlinks on Windows 2018-06-11 11:31:31 +01:00
Simon Butcher
ee3a3d4a72 Merge remote-tracking branch 'public/pr/1470' into mbedtls-2.7 2018-06-11 11:30:33 +01:00
Simon Butcher
4e5edf3184 Add ChangeLog entry for _WIN32_WINNT override fix 2018-06-08 16:23:17 +01:00
Fabio Alessandrelli
ec4ce37709 Only redefine _WIN32_WINNT macro when < 0x0501 2018-06-08 12:28:47 +01:00
Simon Butcher
bb5e1c3973 Fix multiple quality issues in the source
This PR fixes multiple issues in the source code to address issues raised by
tests/scripts/check-files.py. Specifically:
 * incorrect file permissions
 * missing newline at the end of files
 * trailing whitespace
 * Tabs present
 * TODOs in the souce code
2018-06-08 11:14:43 +01:00
Gilles Peskine
db37cb4752 mbedtls_gcm_crypt_and_tag: clarify what each mode does and doesn't do 2018-06-07 15:06:02 +02:00
Gilles Peskine
bb07ca0bfb Fix Lucky13 attack protection when using HMAC-SHA-384
As a protection against the Lucky Thirteen attack, the TLS code for
CBC decryption in encrypt-then-MAC mode performs extra MAC
calculations to compensate for variations in message size due to
padding. The amount of extra MAC calculation to perform was based on
the assumption that the bulk of the time is spent in processing
64-byte blocks, which was correct for most supported hashes but not for
SHA-384. Adapt the formula to 128-byte blocks for SHA-384.
2018-06-06 17:23:31 +02:00
Gilles Peskine
282bd24a44 Correct and clarify the documentation of GCM whole-message functions
Clarify the roles of the buffer parameter and their sizes.

Remove a statement about input size restrictions that only applies to
mbedtls_gcm_update, not to the whole-message functions.

Document the possible error codes.

Warn that mbedtls_gcm_crypt_and_tag in decrypt mode does not
authenticate the data and recommend using mbedtls_gcm_auth_decrypt
instead.
2018-06-06 16:57:03 +02:00