Skip to content

Update Mbed Crypto with latest Mbed TLS changes as of 2019-11-15 #322

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
421 commits
Select commit Hold shift + click to select a range
be34e8e
Remove reference to outdated compile-time option
Jun 4, 2019
afa8f71
Add new config MBEDTLS_SSL_CONTEXT_SERIALIZATION
mpg May 28, 2019
ac87e28
Declare and document ssl_context_save()/load()
mpg May 28, 2019
6d8f128
Fix typos, grammar and wording in documentation
mpg Jun 5, 2019
d0a86f9
Clarify documentation of mbedtls_ssl_context_load()
mpg Jun 11, 2019
9831c8a
Add option for serialization in ssl_client/server2
May 29, 2019
77e6665
Serialization/deserialization in ssl_client2
May 29, 2019
af30629
Rely on opt.exchanges for sending after serialization
May 29, 2019
5a3a16c
Serialize/deserialize for ssl_server2
May 29, 2019
bbc7b41
Use MBEDTLS_SSL_CONTEXT_SERIALIZATION flag
Jun 4, 2019
2937d81
Add serialization tests to ssl-opt.sh
Jun 4, 2019
cbee1b3
Add missing slashes to tests
Jun 4, 2019
a0b2cd6
ssl-opt.sh tests for serialization are currently using stub implement…
Jun 4, 2019
378d64d
Remove mbedtls_ssl_free() and mbedtls_ssl_init() from serialization f…
Jun 4, 2019
93c6ff2
Address review comments for code-style issues
Jun 4, 2019
1d1657f
Allow stub implementation of the context_save for now
Jun 4, 2019
12021ee
Fix spacing
Jun 6, 2019
304d61c
Add option for ssl-context re-initialization flow
Jun 6, 2019
c2376f0
Add tests for re-init flow for context serialization
Jun 6, 2019
15b3a7a
Fix compiler warnings
Jun 6, 2019
1a7f793
Fix spacing
Jun 7, 2019
8e25321
Set timer callbacks with serialization
Jun 13, 2019
ddf72a1
Fix style issues
Jun 13, 2019
96fb0ee
Save Hello random bytes for later use
mpg Jul 9, 2019
1aaf669
Implement usage checks in context_save()
mpg Jul 10, 2019
00400c2
Document internal serialisation format
mpg Jul 10, 2019
0ff7640
Add usage checks in context_load()
mpg Jul 11, 2019
4c90e85
Add (stub) header writing and checking
mpg Jul 11, 2019
4b7e6b9
Add session saving/loading
mpg Jul 11, 2019
a88399c
Improve demo/testing code in client/server2
mpg Jul 12, 2019
b9dfc9f
Fix English in comments
mpg Jul 12, 2019
c2a7b89
Add transform (de)serialization
mpg Jul 15, 2019
3309a67
Fix memory leak in client/server2
mpg Jul 15, 2019
c86c5df
Add saved fields from top-level structure
mpg Jul 15, 2019
0eb3eac
Add setting of forced fields when deserializing
mpg Jul 15, 2019
13c8e68
Change requirements for setting timer callback
mpg Jul 15, 2019
862b319
Enable serialisation tests in ssl-opt.sh
mpg Jul 23, 2019
142ba73
Re-use buffer allocated by handshake_init()
mpg Jul 23, 2019
9df5a82
Actually reset the context on save as advertised
mpg Jul 23, 2019
5ea13b8
Fix compiler warning: comparing signed to unsigned
mpg Jul 23, 2019
5c0e377
Provide serialisation API only if it's enabled
mpg Jul 23, 2019
4e9370b
Implement config-checking header to context s11n
mpg Jul 23, 2019
45ac1f0
Avoid duplication of session format header
mpg Jul 23, 2019
9a96fd7
Fix compile error in reduced configurations
mpg Jul 23, 2019
f041f4e
Fix MSVC warning
mpg Jul 23, 2019
4ca930f
Fix a typo in a comment
mpg Jul 26, 2019
e458869
Improve reability and debugability of large if
mpg Jul 29, 2019
c84bd24
Add missing guards for mac usage
Aug 16, 2019
b9ca1b0
Fix parameter name in doxygen
Aug 20, 2019
bccf035
Remove duplicate entries from ChangeLog
Aug 20, 2019
8c51b7c
Add debug messages
Aug 21, 2019
b7b486c
Fix compiler warning
Aug 21, 2019
9e90df5
Add changelog entry to record checking
Aug 23, 2019
472a2a2
Don't redefine calloc and free
Aug 23, 2019
b2d61e3
Merge remote-tracking branch 'origin/pr/2792' into development
Patater Aug 27, 2019
f1cdcea
Merge remote-tracking branch 'origin/development' into development-re…
Patater Aug 27, 2019
4e0db56
Merge branch 'mbedtls-2.18' into development
Patater Aug 27, 2019
cfc9c8c
Merge remote-tracking branch 'origin/pr/2798' into development
Patater Aug 29, 2019
3ec5047
Merge remote-tracking branch 'origin/pr/2807' into development
Patater Aug 29, 2019
64f2643
Merge remote-tracking branch 'origin/development' into development-re…
Patater Aug 29, 2019
02b8048
ECDH: Add Everest Curve25519 config.h option
Oct 25, 2018
977d89a
ECDH: Include Everest Curve25519 in build scripts
Oct 25, 2018
0bc9c69
ECDH: Add new (non-legacy) ECDH benchmark
Oct 25, 2018
e0e8eb3
ECDH: Add #ifdef filter to tests/scripts/list-enum-consts.pl
Oct 25, 2018
0b93102
ECDH: Rename full handshake benchmark
Dec 6, 2018
b4e63a1
ECDH: Improve ECDH full handshake benchmark
Dec 7, 2018
c14dd84
ECDH: Add Everest Curve25519 to VS project files
Dec 6, 2018
e50b970
ECDH: Fix whitespace and doxygen comment
Dec 14, 2018
f4bee2f
ECDH: Use LOCAL_CFLAGS instead of CFLAGS
Dec 14, 2018
3dca1a4
ECDH: Fix error checks in benchmark.c
Dec 14, 2018
e14c779
ECDH: Everest: Remove unnecessary file
Dec 14, 2018
89f36ae
Add new 3rdparty build scripts
Dec 14, 2018
346932a
Fix preprocessor directive recognition in list-enum-consts.pl
Dec 14, 2018
9b33e7d
ECDH: Exclude FStar and Hacl* from exported symbol checks
Dec 14, 2018
6a1a9e4
ECDSA: Add mbedtls_ecdsa_can_do
Jan 7, 2019
b33e811
ECDH: Fix file permission problem
Jan 7, 2019
6cddd30
ECDH: Disable Everest by default
Jan 17, 2019
181f284
config.h: Silence missing documentation warning
Jan 17, 2019
655ddab
3rdparty: Add additional build facilities for 3rd-party code
Jan 21, 2019
21411d2
ECDH: Make benchmarks check MBEDTLS_ERR_PLATFORM_FEATURE_UNSUPPORTED
Feb 6, 2019
b14c4a5
Fix build with gcc -Wshadow
gilles-peskine-arm Feb 11, 2019
c6c7c49
Add mbedtls_ecdh_can_do
gilles-peskine-arm Feb 11, 2019
7e65c05
Document that curve lists can include partially-supported curves
gilles-peskine-arm Feb 11, 2019
0a92cc1
Add a changelog entry for Everest ECDH (X25519)
gilles-peskine-arm Feb 11, 2019
8cd4fba
ECDSA: Refactor return value checks for mbedtls_ecdsa_can_do
Feb 15, 2019
37eb906
3rdparty: Fix Makefile coding conventions
Feb 15, 2019
50d9f09
3rdparty: Update description of MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED
Feb 15, 2019
54d09ad
3rdparty: Rename THIRDPARTY_OBJECTS
Feb 15, 2019
e1dfc98
Fix file permissions
Feb 15, 2019
ed5f3f0
ECDH: Fix Everest x25519 make_public
Feb 15, 2019
1a2d9f7
ECDH: Removed unnecessary calls to mbedtls_ecp_group_load in ECDH ben…
Feb 15, 2019
5d536cd
ECDH: Fix use of ECDH API in full handshake benchmark
Feb 20, 2019
cc91fe2
ECDH: Fix inclusion of platform.h for proper use of MBEDTLS_ERR_PLATF…
Feb 20, 2019
12f359f
Fix trailing whitespace
Feb 26, 2019
015f55b
3rdparty: Fix inclusion order of CMakeLists.txt
Apr 8, 2019
3669c80
Update generated files
Apr 12, 2019
9e8076f
Fix macros in benchmark.c
Apr 15, 2019
9c1b56b
3rdparty: Add config checks for Everest
Apr 15, 2019
0c6b799
Add Everest components to all.sh
gilles-peskine-arm Apr 12, 2019
4f055f4
Use 3rdparty headers from the submodule
yanesca Aug 20, 2019
31465c6
Update submodule
yanesca Aug 20, 2019
361b10d
Fix SSL context deserialization
Aug 30, 2019
1b18fd3
ssl-opt.sh: Duplicate context serialization tests for CID
Aug 30, 2019
e0b90ec
ssl-opt.sh: Add var's of context s11n tests for ChaChaPoly,CCM,GCM
Aug 30, 2019
1f62714
Fix uninitialized variable in x509_crt
Jan 30, 2019
fe997c6
Update library version to 2.19.0
dgreen-arm Aug 30, 2019
84f5d03
Merge remote-tracking branch 'origin/pr/2810' into development
Patater Aug 30, 2019
379964a
Merge remote-tracking branch 'origin/pr/2814' into development
Patater Aug 30, 2019
d031378
Merge remote-tracking branch 'origin/development' into development-re…
Patater Aug 30, 2019
9b9a790
Handle deleting non-existant files on Windows
dgreen-arm Aug 30, 2019
49fcbea
Merge remote-tracking branch 'origin/pr/2799' into development
Patater Aug 30, 2019
4cf0e7e
Merge remote-tracking branch 'origin/development' into development-re…
Patater Aug 30, 2019
d364f4c
ssl-opt.sh: wait for proxy to start before running the script further
AndrzejKurek Sep 2, 2019
c6f1c84
Remove config.pl calls with no effect
gilles-peskine-arm Sep 3, 2019
751bb4c
Disable MEMORY_BUFFER_ALLOC with ASan
gilles-peskine-arm Jul 31, 2019
6ce3072
When not using PSA crypto, disable it
gilles-peskine-arm Jul 31, 2019
dc3a179
Fix copypasta in msg
gilles-peskine-arm Sep 3, 2019
a66fc94
Merge remote-tracking branch 'origin/pr/2363' into development
Patater Sep 3, 2019
3f0fc38
Merge remote-tracking branch 'origin/pr/2795' into development
Patater Sep 3, 2019
8dd6bc7
Merge remote-tracking branch 'origin/pr/2803' into development
Patater Sep 3, 2019
481659a
Merge remote-tracking branch 'origin/development' into development-re…
Patater Sep 3, 2019
ba7f4d1
Merge remote-tracking branch 'origin/pr/2771' into development
Patater Sep 5, 2019
4714fd8
Merge remote-tracking branch 'origin/pr/2815' into development
Patater Sep 5, 2019
aeb5a4a
Merge remote-tracking branch 'origin/pr/2623' into development
Patater Sep 5, 2019
2f18490
Update crypto submodule to include deterministic ECDSA RNG fix
dgreen-arm Sep 5, 2019
12fff15
Add ChangeLog entries
yanesca Jan 4, 2019
c9c4ca3
Merge remote-tracking branch 'origin/development' into development-re…
Patater Sep 5, 2019
4799df7
Merge remote-tracking branch 'restricted/pr/547' into development-res…
Patater Sep 6, 2019
7ecae6f
Update to Mbed Crypto 2.0.0d2
Patater Sep 6, 2019
af46c5f
Check dependencies of MBEDTLS_MEMORY_BACKTRACE in check_config.h
Feb 26, 2019
909e68d
Disable memory buffer allocator in full config
Feb 26, 2019
790c281
Adapt all.sh to removal of buffer allocator from full config
AndrzejKurek Sep 4, 2019
2ea2f05
Update documentation of exceptions for `config.pl full`
Feb 26, 2019
0fb9ba2
Add all.sh run with MBEDTLS_MEMORY_BUFFER_ALLOC_C enabled
Feb 26, 2019
0163551
Add all.sh run with full config and ASan enabled
Feb 26, 2019
2fcdd74
Fix a memory leak in x509write test suite
Feb 26, 2019
bf2dacb
Fix memory leak in CSR test suite on failure
Jun 3, 2019
bfaa718
Add cfg dep MBEDTLS_MEMORY_DEBUG->MBEDTLS_MEMORY_BUFFER_ALLOC_C
Jun 3, 2019
dc54953
Don't set MBEDTLS_MEMORY_DEBUG through `scripts/config.pl full`
Jun 3, 2019
d706420
Add missing dependency in memory buffer alloc set in all.sh
Jun 3, 2019
69f20aa
all.sh: restructure memory allocator tests
Sep 5, 2019
1e56d2c
Disable DTLS proxy tests for MEMORY_BUFFER_ALLOC test
Sep 5, 2019
4b3a45e
Remove unnecessary memory buffer alloc unsets
Sep 6, 2019
4197f0e
ChangeLog: Update for 2.19.0
Patater Sep 6, 2019
48f3a3d
Add NSS keylog support to ssl_server2 and ssl_client2
Aug 29, 2019
bc5308c
ssl_cli/srv2: Indicate nss_keylog and eap_tls are mut. exclusive
Sep 9, 2019
9f409f6
Enable MBEDTLS_MEMORY_DEBUG in memory buffer alloc test in all.sh
Sep 10, 2019
0eb2d9d
Update Coverity secure token
jainvikas8 Sep 10, 2019
3760083
Merge pull request #2809 from hanno-arm/nss_keylog-dev
Patater Sep 11, 2019
2dedcc5
Change X.509 test cases to not rely on asn1parse limitations
gilles-peskine-arm Sep 11, 2019
fdbdc37
Remove blocked branches
jainvikas8 Sep 10, 2019
2bcf51a
Update notification e-mail address
jainvikas8 Sep 10, 2019
63d813d
ssl: Disallow modification of hello.random by export
Patater Sep 12, 2019
fa63645
ssl: Remove key exporter bug workaround
Patater Sep 12, 2019
62be28b
Merge remote-tracking branch 'origin/pr/2469' into development
Patater Sep 12, 2019
b406389
Mbed TLS configuration file manipulation library and tool
gilles-peskine-arm Jul 27, 2019
53d41ae
Implement the 'full' and 'baremetal' configurations
gilles-peskine-arm Jul 27, 2019
6c2d078
Remove obsolete options from config.py
gilles-peskine-arm Jul 27, 2019
2d89ccc
Sort symbol lists in alphabetical order
gilles-peskine-arm Jul 27, 2019
5639aef
Uniformize whitespace in commented-out defines
gilles-peskine-arm Jul 27, 2019
40f103c
Support writing to a different file
gilles-peskine-arm Jul 27, 2019
5d46f6a
Invoke config.py instead of config.pl
gilles-peskine-arm Jul 27, 2019
bf359c7
Replace config.pl by a redirection to config.py
gilles-peskine-arm Jul 27, 2019
90b30b6
Print help when invoked with no arguments
gilles-peskine-arm Jul 27, 2019
0fa5efb
Fix encoding errors
gilles-peskine-arm Jul 28, 2019
98eb365
Fix 'config.py set' without --force
gilles-peskine-arm Jul 28, 2019
6cf3127
Report an error if switching to Python fails
gilles-peskine-arm Jul 29, 2019
208e4ec
Also search config.h near the script
gilles-peskine-arm Jul 29, 2019
55cc4db
Fix Config.unset() making the name known
gilles-peskine-arm Aug 1, 2019
435ce22
Fix --force requiring an argument
gilles-peskine-arm Aug 1, 2019
0c7fcd2
Fix "--force set" without a value sneaking a None in
gilles-peskine-arm Aug 1, 2019
221df1e
Fix "#define ... not found" error when using the default file name
gilles-peskine-arm Aug 1, 2019
c190c90
Documentation improvements
gilles-peskine-arm Aug 1, 2019
878acd6
Test script for config.py
gilles-peskine-arm Aug 1, 2019
2fd7ffa
cmake: fix Python requirement
gilles-peskine-arm Sep 4, 2019
00ed2e1
cmake: update interpreter requirement for the test suite generator
gilles-peskine-arm Sep 4, 2019
e3734bd
Remove redundant test case
gilles-peskine-arm Sep 4, 2019
f686042
Fix config.py output when a symbol has acquired or lost a value
gilles-peskine-arm Sep 4, 2019
a103c18
Compatibility redirect: if python3 is not available, try python
gilles-peskine-arm Sep 5, 2019
0409bcd
Compatibility redirect: add copyright notice
gilles-peskine-arm Sep 13, 2019
61695e7
config.py testing: also test the get command
gilles-peskine-arm Sep 13, 2019
46d61b1
Merge remote-tracking branch 'origin/pr/2834' into development
Patater Sep 13, 2019
b2ab86c
crypto: Update submodule to 3f20efc03016
Patater Sep 16, 2019
a5fb316
Merge pull request #2842 from Patater/crypto-to-3f20efc03016
Patater Sep 17, 2019
914a507
Bump Mbed TLS version to 2.19.1
Patater Sep 18, 2019
c835672
Merge remote-tracking branch 'origin/pr/2846' into development
Patater Sep 18, 2019
a708dae
Add comment to help syntax highlighting in editors
gilles-peskine-arm Sep 16, 2019
3c1c8ea
Prefer unsigned types for non-negative numbers
gilles-peskine-arm Sep 16, 2019
31fccc8
Fix typo in message
gilles-peskine-arm Sep 16, 2019
47b7540
Give a type name to test_info
gilles-peskine-arm Sep 16, 2019
51dcc24
Test outcome file support: test suites
gilles-peskine-arm Sep 16, 2019
560280b
Test outcome file support: ssl-opt.sh
gilles-peskine-arm Sep 16, 2019
654bab7
ssl-opt: remove semicolons from test case descriptions
gilles-peskine-arm Sep 16, 2019
9004a17
Set meaningful test configuration names when running tests
gilles-peskine-arm Sep 16, 2019
fd7ad33
Consolidate tests for set with/without values
gilles-peskine-arm Sep 19, 2019
16a25e0
Add set+get tests
gilles-peskine-arm Sep 19, 2019
311f54d
tls_prf: support an empty master secret
gilles-peskine-arm Sep 23, 2019
c21a9f0
Merge remote-tracking branch 'origin/pr/2765' into development
Patater Sep 23, 2019
d1798b4
Merge remote-tracking branch 'origin/pr/2821' into development
Patater Sep 23, 2019
67ffdaf
all.sh --outcome-file creates an outcome file
gilles-peskine-arm Sep 16, 2019
d46b086
Create infrastructure for architecture documents in Markdown
gilles-peskine-arm Sep 16, 2019
508caf5
Document the test outcome file
gilles-peskine-arm Sep 16, 2019
ba94b58
New test script check-test-cases.py
gilles-peskine-arm Sep 16, 2019
7a020f3
Make test case descriptions unique
gilles-peskine-arm Sep 16, 2019
a9478ba
Fix configuration short name in key-exchanges.pl
gilles-peskine-arm Sep 18, 2019
600bb69
Better information messages for quick checks
gilles-peskine-arm Sep 19, 2019
895868b
all.sh: run check-test-cases.py
gilles-peskine-arm Sep 19, 2019
168858f
Fix regex matching run_test calls in ssl-opt.sh
gilles-peskine-arm Sep 20, 2019
283df2e
Fix cosmetic error in warnings
gilles-peskine-arm Sep 20, 2019
32b9421
Factor description-checking code into a common function
gilles-peskine-arm Sep 20, 2019
f12ad58
Process input files as binary
gilles-peskine-arm Sep 20, 2019
57870e8
Reject non-ASCII characters in test case descriptions
gilles-peskine-arm Sep 20, 2019
0d8b86a
ssl-opt.sh: Fix some test case descriptions
gilles-peskine-arm Sep 20, 2019
2a70304
Update crypto submodule to support EAP-TLS key derivation
gilles-peskine-arm Sep 23, 2019
bdcca14
Merge remote-tracking branch 'upstream-public/pr/2858' into development
gilles-peskine-arm Sep 27, 2019
717cd76
Restore MBEDTLS_TEST_OUTCOME_FILE after test_default_out_of_box
gilles-peskine-arm Sep 27, 2019
e94bc87
Document test case descriptions
gilles-peskine-arm Sep 27, 2019
013ba71
Update the crypto submodule to be the same as development
gilles-peskine-arm Sep 27, 2019
7334462
Make hyperlink a hyperlink in every markdown flavor
gilles-peskine-arm Oct 1, 2019
230b87a
Merge remote-tracking branch 'origin/pr/2843' into development
Patater Oct 2, 2019
74692ae
Merge remote-tracking branch 'origin/pr/2488' into development
Patater Oct 2, 2019
714c3e1
Update crypto submodule
gilles-peskine-arm Oct 4, 2019
e96658d
Update error.c after a crypto submodule update
gilles-peskine-arm Oct 4, 2019
f70d3eb
Uncomment X509 test that now works
gilles-peskine-arm Oct 4, 2019
8af3923
Add a recipe for libmbedcrypto with a path prefix
Oct 7, 2019
df2cd9e
Makefiles: move the dependencies block to be after DLEXT definition
Oct 7, 2019
232e8f9
Enable parallel shared target tests
Oct 3, 2019
0d50d41
Merge pull request #2882 from gilles-peskine-arm/update-crypto-20191004
gilles-peskine-arm Oct 8, 2019
8028cb1
Makefile: add path prefixes to other versions of libmbedcrypto library
Oct 8, 2019
e601625
Update crypto submodule
gilles-peskine-arm Oct 11, 2019
1b717c9
Merge pull request #2887 from gilles-peskine-arm/update-crypto-20191011
Patater Oct 14, 2019
719ae74
Merge pull request #2884 from AndrzejKurek/iotssl-2886-fix-parallel-m…
Patater Oct 18, 2019
8fd5942
Unify ASan options in make builds
gilles-peskine-arm Oct 21, 2019
2558d30
Use UBsan in addition to Asan with 'make test'
gilles-peskine-arm Oct 21, 2019
5ca393f
Asan make builds: avoid sanitizer recovery
gilles-peskine-arm Oct 21, 2019
ce35cb3
'make test' must fail if Asan fails
gilles-peskine-arm Oct 21, 2019
b23abcb
Merge pull request #2898 from gilles-peskine-arm/asan-test-fail-devel…
Patater Oct 22, 2019
7f8089b
Fix mbedtls_ssl_check_record usage with ext buf
Oct 29, 2019
7b6d8c2
Merge pull request #2909 from artokin/mbedtls_replay_check_fix_backport
gilles-peskine-arm Oct 29, 2019
6ffac75
x509write_csr: Reduce stack usage of mbedtls_x509write_csr_pem()
Patater Oct 18, 2019
e1853a2
Update crypto submodule
gilles-peskine-arm Nov 8, 2019
bf88780
Use MBEDTLS_PK_SIGNATURE_MAX_SIZE in X.509
gilles-peskine-arm Nov 8, 2019
96a7cd1
Use MBEDTLS_PK_SIGNATURE_MAX_SIZE in pkey sample programs
gilles-peskine-arm Nov 8, 2019
2e86a20
Remove component designed to test MAX_SIGNATURE_SIZE
gilles-peskine-arm Nov 8, 2019
b9b5f49
Merge pull request #2920 from gilles-peskine-arm/pk_signature_max_siz…
gilles-peskine-arm Nov 14, 2019
df8185e
Merge pull request #2923 from Patater/reduce-ram-pem-csr
Patater Nov 14, 2019
43259ce
Remove unused test data file
gilles-peskine-arm Nov 14, 2019
4ebb782
Merge pull request #2926 from gilles-peskine-arm/pk_signature_max_siz…
Patater Nov 15, 2019
9afbfdc
Merge remote-tracking branch 'myfork-public/development' into merge-c…
gilles-peskine-arm Nov 15, 2019
24600e8
Disable memory_buffer_alloc in the full config
gilles-peskine-arm Nov 15, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 2 additions & 8 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,6 @@ compiler:
sudo: false
cache: ccache

# blocklist
branches:
except:
- development-psa
- coverity_scan

script:
- tests/scripts/recursion.pl library/*.c
- tests/scripts/check-generated-files.sh
Expand All @@ -27,7 +21,7 @@ script:
env:
global:
- SEED=1
- secure: "barHldniAfXyoWOD/vcO+E6/Xm4fmcaUoC9BeKW+LwsHqlDMLvugaJnmLXkSpkbYhVL61Hzf3bo0KPJn88AFc5Rkf8oYHPjH4adMnVXkf3B9ghHCgznqHsAH3choo6tnPxaFgOwOYmLGb382nQxfE5lUdvnM/W/psQjWt66A1+k="
- secure: "FrI5d2s+ckckC17T66c8jm2jV6i2DkBPU5nyWzwbedjmEBeocREfQLd/x8yKpPzLDz7ghOvr+/GQvsPPn0dVkGlNzm3Q+hGHc/ujnASuUtGrcuMM+0ALnJ3k4rFr9xEvjJeWb4SmhJO5UCAZYvTItW4k7+bj9L+R6lt3TzQbXzg="

addons:
apt:
Expand All @@ -37,7 +31,7 @@ addons:
coverity_scan:
project:
name: "ARMmbed/mbedtls"
notification_email: simon.butcher@arm.com
notification_email: support-mbedtls@arm.com
build_command_prepend:
build_command: make
branch_pattern: coverity_scan
1 change: 1 addition & 0 deletions docs/architecture/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ default: all
all_markdown = \
mbed-crypto-storage-specification.md \
testing/driver-interface-test-strategy.md \
testing/test-framework.md \
# This line is intentionally left blank

html: $(all_markdown:.md=.html)
Expand Down
58 changes: 58 additions & 0 deletions docs/architecture/testing/test-framework.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# Mbed TLS test framework

This document is an overview of the Mbed TLS test framework and test tools.

This document is incomplete. You can help by expanding it.

## Unit tests

See <https://tls.mbed.org/kb/development/test_suites>

### Unit test descriptions

Each test case has a description which succinctly describes for a human audience what the test does. The first non-comment line of each paragraph in a `.data` file is the test description. The following rules and guidelines apply:

* Test descriptions may not contain semicolons, line breaks and other control characters, or non-ASCII characters. <br>
Rationale: keep the tools that process test descriptions (`generate_test_code.py`, [outcome file](#outcome-file) tools) simple.
* Test descriptions must be unique within a `.data` file. If you can't think of a better description, the convention is to append `#1`, `#2`, etc. <br>
Rationale: make it easy to relate a failure log to the test data. Avoid confusion between cases in the [outcome file](#outcome-file).
* Test descriptions should be a maximum of **66 characters**. <br>
Rationale: 66 characters is what our various tools assume (leaving room for 14 more characters on an 80-column line). Longer descriptions may be truncated or may break a visual alignment. <br>
We have a lot of test cases with longer descriptions, but they should be avoided. At least please make sure that the first 66 characters describe the test uniquely.
* Make the description descriptive. “foo: x=2, y=4” is more descriptive than “foo #2”. “foo: 0<x<y, both even” is even better if these inequalities and parities are why this particular test data was chosen.
* Avoid changing the description of an existing test case without a good reason. This breaks the tracking of failures across CI runs, since this tracking is based on the descriptions.

`tests/scripts/check-test-cases.py` enforces some rules and warns if some guidelines are violated.

## TLS tests

### SSL extension tests

#### SSL test case descriptions

Each test case in `ssl-opt.sh` has a description which succinctly describes for a human audience what the test does. The test description is the first parameter to `run_tests`.

The same rules and guidelines apply as for [unit test descriptions](#unit-test-descriptions). In addition, the description must be written on the same line as `run_test`, in double quotes, for the sake of `check-test-cases.py`.

## Running tests

### Outcome file

#### Generating an outcome file

Unit tests and `ssl-opt.sh` record the outcome of each test case in a **test outcome file**. This feature is enabled if the environment variable `MBEDTLS_TEST_OUTCOME_FILE` is set. Set it to the path of the desired file.

If you run `all.sh --outcome-file test-outcome.csv`, this collects the outcome of all the test cases in `test-outcome.csv`.

#### Outcome file format

The outcome file is in a CSV format using `;` (semicolon) as the delimiter and no quoting. This means that fields may not contain newlines or semicolons. There is no title line.

The outcome file has 6 fields:

* **Platform**: a description of the platform, e.g. `Linux-x86_64` or `Linux-x86_64-gcc7-msan`.
* **Configuration**: a unique description of the configuration (`config.h`).
* **Test suite**: `test_suite_xxx` or `ssl-opt`.
* **Test case**: the description of the test case.
* **Result**: one of `PASS`, `SKIP` or `FAIL`.
* **Cause**: more information explaining the result.
2 changes: 1 addition & 1 deletion doxygen/mbedtls.doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ DOXYFILE_ENCODING = UTF-8
# identify the project. Note that if you do not use Doxywizard you need
# to put quotes around the project name if it contains spaces.

PROJECT_NAME = "mbed TLS v2.17.0"
PROJECT_NAME = "mbed TLS v2.19.1"

# The PROJECT_NUMBER tag can be used to enter a project or revision number.
# This could be handy for archiving the generated documentation or
Expand Down
8 changes: 8 additions & 0 deletions include/mbedtls/check_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,14 @@
#error "MBEDTLS_MEMORY_BUFFER_ALLOC_C defined, but not all prerequisites"
#endif

#if defined(MBEDTLS_MEMORY_BACKTRACE) && !defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C)
#error "MBEDTLS_MEMORY_BACKTRACE defined, but not all prerequesites"
#endif

#if defined(MBEDTLS_MEMORY_DEBUG) && !defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C)
#error "MBEDTLS_MEMORY_DEBUG defined, but not all prerequesites"
#endif

#if defined(MBEDTLS_PADLOCK_C) && !defined(MBEDTLS_HAVE_ASM)
#error "MBEDTLS_PADLOCK_C defined, but not all prerequisites"
#endif
Expand Down
1 change: 1 addition & 0 deletions include/mbedtls/error.h
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@
* ECP 4 10 (Started from top)
* MD 5 5
* HKDF 5 1 (Started from top)
* SSL 5 1 (Started from 0x5F00)
* CIPHER 6 8 (Started from 0x6080)
* SSL 6 24 (Started from top, plus 0x6000)
* SSL 7 32
Expand Down
10 changes: 5 additions & 5 deletions include/mbedtls/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,17 +39,17 @@
* Major, Minor, Patchlevel
*/
#define MBEDTLS_VERSION_MAJOR 2
#define MBEDTLS_VERSION_MINOR 17
#define MBEDTLS_VERSION_PATCH 0
#define MBEDTLS_VERSION_MINOR 19
#define MBEDTLS_VERSION_PATCH 1

/**
* The single version number has the following structure:
* MMNNPP00
* Major version | Minor version | Patch version
*/
#define MBEDTLS_VERSION_NUMBER 0x02110000
#define MBEDTLS_VERSION_STRING "2.17.0"
#define MBEDTLS_VERSION_STRING_FULL "mbed TLS 2.17.0"
#define MBEDTLS_VERSION_NUMBER 0x02130100
#define MBEDTLS_VERSION_STRING "2.19.1"
#define MBEDTLS_VERSION_STRING_FULL "mbed TLS 2.19.1"

#if defined(MBEDTLS_VERSION_C)

Expand Down
4 changes: 3 additions & 1 deletion library/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -146,9 +146,11 @@ libmbedcrypto.dll: $(OBJS_CRYPTO)
echo " LD $@"
$(CC) -shared -Wl,-soname,$@ -Wl,--out-implib,$@.a -o $@ $(OBJS_CRYPTO) -lws2_32 -lwinmm -lgdi32 -static-libgcc $(LOCAL_LDFLAGS) $(LDFLAGS)

libmbedcrypto.$(DLEXT): | libmbedcrypto.a

.c.o:
echo " CC $<"
$(CC) $(LOCAL_CFLAGS) $(CFLAGS) -c $< -o $@
$(CC) $(LOCAL_CFLAGS) $(CFLAGS) -o $@ -c $<

clean:
ifndef WINDOWS
Expand Down
4 changes: 2 additions & 2 deletions programs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -249,8 +249,8 @@ ifndef WINDOWS
rm -f $(APPS) $(EXTRA_GENERATED)
-rm -f test/cpp_dummy_build$(EXEXT)
else
if exist *.o del /S /Q /F *.o
if exist *.exe del /S /Q /F *.exe
if exist *.o del /Q /F *.o
if exist *.exe del /Q /F *.exe
if exist $(EXTRA_GENERATED) del /S /Q /F $(EXTRA_GENERATED)
endif

Expand Down
1 change: 0 additions & 1 deletion programs/pkey/pk_sign.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ int main( void )
#include <stdio.h>
#include <string.h>


int main( int argc, char *argv[] )
{
FILE *f;
Expand Down
5 changes: 3 additions & 2 deletions scripts/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,9 @@ def include_in_full(name):
'MBEDTLS_ECDH_VARIANT_EVEREST_ENABLED',
'MBEDTLS_ECP_RESTARTABLE',
'MBEDTLS_HAVE_SSE2',
'MBEDTLS_MEMORY_BACKTRACE',
'MBEDTLS_MEMORY_BUFFER_ALLOC_C',
'MBEDTLS_MEMORY_DEBUG',
'MBEDTLS_NO_64BIT_MULTIPLICATION',
'MBEDTLS_NO_DEFAULT_ENTROPY_SOURCES',
'MBEDTLS_NO_PLATFORM_ENTROPY',
Expand Down Expand Up @@ -201,8 +204,6 @@ def keep_in_baremetal(name):
'MBEDTLS_HAVEGE_C',
'MBEDTLS_HAVE_TIME',
'MBEDTLS_HAVE_TIME_DATE',
'MBEDTLS_MEMORY_BACKTRACE',
'MBEDTLS_MEMORY_BUFFER_ALLOC_C',
'MBEDTLS_PLATFORM_FPRINTF_ALT',
'MBEDTLS_PLATFORM_TIME_ALT',
'MBEDTLS_PSA_CRYPTO_SE_C',
Expand Down
Loading