-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
mbedtls_mpi_copy optimization #405
mbedtls_mpi_copy optimization #405
Conversation
Automatic CI verification build not done, please verify manually. |
Hi @pieceofsummer, You've made quite a few contributions which I think we'd like to accept, but to accept these or any future contributions we will need a Contributor’s Licence Agreement (CLA) signed or authorised by yourself. You can find an agreement to sign here, which can be signed and returned to us, or you could create an mbed account and accept a slightly different agreement here with a click through if this is a personal contribution. Thanks for your understanding, and apologies it's taken so long to come back to you since you made the contribution. |
Automatic CI verification build not done, please verify manually. |
@sbutcher-arm I've chosen the second option (since it is a personal contribution) and created an account. Shouldn't be an issue anymore. |
Thanks for authorising the CLA! Can you confirm your mbed User account name, so I can cross-reference? You can email me this privately if you prefer. |
Ok, I think I checked too soon after you'd created the account. I can now see you, and that you've accepted the CLA. Thanks again! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
Only known timing tests failed in CI. @gilles-peskine-arm please consider merging. |
@@ -200,7 +200,13 @@ int mbedtls_mpi_copy( mbedtls_mpi *X, const mbedtls_mpi *Y ) | |||
|
|||
MBEDTLS_MPI_CHK( mbedtls_mpi_grow( X, i ) ); | |||
|
|||
memset( X->p, 0, X->n * ciL ); | |||
if( X->n > i ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's good, but we can do a little better: if X
is larger, there's no need to call mbedtls_mpi_grow
. I'll make a patch → #1480
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if( i > X->n )
is checked inside mbedtls_mpi_grow( X, i )
. If we change here we have to repeat the condition here. Since, else can be i == X->n
. Hence not much better than what this PR adds.
Based on a contribution by Alexey Skalozub (Mbed-TLS#405).
@pieceofsummer Thank you for this contribution. We have created PR #1480 which has your changes, some more improvements and an additional commit adding a ChangeLog entry and acknowledging your contribution, so I am now closing this PR. |
A patch based on your contribution has been merged through #1480. Thank you! |
Squashed commit of the following: commit 070e356476ae3df495c306c1bfc43c7ed9d32fc7 Merge: 78d2f7d e6a2a1a Author: Jaeden Amero <jaeden.amero@arm.com> Date: Tue May 1 15:28:18 2018 +0100 Merge remote-tracking branch 'upstream-restricted/pr/481' into development-restricted commit e6a2a1aa97585fc5638953633ae6968d910a0b58 Author: Simon Butcher <simon.butcher@arm.com> Date: Tue May 1 13:57:53 2018 +0100 Add the uodate to the soversion to the ChangeLog commit 78d2f7d5df221e66d2be3fa90563112aeb22470c Merge: 00cbed2 b03120a Author: Jaeden Amero <jaeden.amero@arm.com> Date: Mon Apr 30 17:37:42 2018 +0100 Merge remote-tracking branch 'upstream-restricted/pr/478' into development-restricted commit b03120ad415e634433f98a82edf4762a9b59fb28 Author: Simon Butcher <simon.butcher@arm.com> Date: Mon Apr 30 16:40:25 2018 +0100 Fix the ChangeLog for clarity, english and credit commit 00cbed23b81b33251f1f31f9471ee43fc9ac7f71 Merge: 8b98498 7d7bad6 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Mon Apr 30 10:21:25 2018 +0100 Merge remote-tracking branch 'upstream-restricted/pr/474' into development-restricted commit 7d7bad6b1ff3a8ac425c5725e29c4711ca22ec32 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Fri Apr 27 13:07:13 2018 +0100 Update version to 2.9.0 Bump SOVERSION for parity with 2.7.2 and 2.7.3. commit 8b98498e9acb3a75387cd4374af69cdb4dea8f7c Merge: c64a300 fe0669f Author: Jaeden Amero <jaeden.amero@arm.com> Date: Fri Apr 27 18:27:47 2018 +0100 Merge remote-tracking branch 'upstream-restricted/pr/477' into development-restricted-proposed commit fe0669f52ac62abf3a25c58e737eb467d013aa31 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Fri Apr 27 17:43:32 2018 +0100 ecp: Fix binary compatibility with group ID We naturally added the new Curve448 ECP group ID in alphabetical order in the mbedtls_ecp_group_id enum. However, this causes binary incompatibility issues as previous binaries will use values for groups that now have a different meaning. For example, MBEDTLS_ECP_DP_SECP192K1, old value 10, would mean Curve448 (MBEDTLS_ECP_DP_CURVE448) and the wrong group ID used. Fix the binary compatibility issue by adding new enum entries to the end of the enum, even though this isn't so great for readbility as the list is no longer in alphabetical order. However, the list wasn't perfectly in alphabetical order before anyway. commit c64a30002722ebf6e728c80078a4bbe0f1208ad2 Merge: bd05dfd b7a18c0 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Thu Apr 26 09:05:34 2018 +0100 Merge remote-tracking branch 'upstream-restricted/pr/471' into development-restricted-proposed Remove trailing whitespace in ChangeLog. commit bd05dfd49f20bd9e83eeed09767cdb1e317ba818 Merge: 8945343 84a1107 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Thu Apr 26 08:59:12 2018 +0100 Merge branch 'development-proposed' into development-restricted-proposed Resolve conflicts in ChangeLog commit 84a1107818aaddfd2abe4c5a3478cf84ab2e26b4 Merge: 38c42d5 a9ceef8 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Apr 25 14:22:12 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1592' into development-proposed commit 38c42d5afa7873831d0289ecd08b1c263b05e488 Merge: 1afdec1 f13ca95 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Apr 25 14:20:08 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1570' into development-proposed Resolve merge conflict in ChangeLog. commit b7a18c049863bcddcc74321a0d32467216f844cd Author: Andrzej Kurek <andrzej.kurek@arm.com> Date: Wed Apr 25 05:25:30 2018 -0400 Changelog entry commit 03bac448db441d66612e2a2ed2c5e2f1ec2b04b8 Author: Andrzej Kurek <andrzej.kurek@arm.com> Date: Wed Apr 25 05:06:07 2018 -0400 Change accepted ciphersuite versions when parsing server hello Accept only ciphersuites for version chosen by the server commit 8945343a513ee462b0fe9f34acdeefc789865e6e Merge: 5450d1f 1afdec1 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Tue Apr 24 17:15:38 2018 +0100 Merge branch 'development-proposed' into development-restricted-proposed Resolve merge conflict in ecp.h, where `mbedtls_ecp_keypair` was moved. commit 1afdec18127f20e821efe9af545bf4f7dd92d142 Merge: 519b129 3dd8abd Author: Jaeden Amero <jaeden.amero@arm.com> Date: Tue Apr 24 14:19:41 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1578' into development-proposed commit 3dd8abd037f9b5a0a7b543fc38e18d0f349b0a42 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Tue Apr 24 10:56:55 2018 +0100 Regenerate errors after ecp.h updates The error descriptions were updated in ecp.h (PR #1578), so also update the strings in error.c. commit 519b129f7810f0ff5843c5d12592a69f622caf4a Merge: 7c68878 fa1fe36 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Tue Apr 24 10:31:32 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1580' into development-proposed commit a7a6155272baaae2a99a0021ac0694842eeac392 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Apr 24 13:14:01 2018 +0100 Update ecp.h One fix. Removed trailing whitespaces commit a9ceef8e032e488e9b3821bfdac4b4dfba2f3a20 Author: Andrzej Kurek <andrzej.kurek@arm.com> Date: Tue Apr 24 06:32:44 2018 -0400 Change variable bytes_written to header_bytes in record decompression The name is changed to better reflect the input, decompression case commit 7c68878e1717153ad22de0947d2f5ad56789522e Merge: d803c1f 6a7ebc4 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Tue Apr 24 10:28:25 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1511' into development-proposed commit d803c1f1ab395341d0ab99e14268fc6dbde37121 Merge: f852f4c abc9ec7 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Tue Apr 24 10:27:38 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1510' into development-proposed Resolve conflict in comment for mbedtls_ecdsa_read_signature in include/mbedtls/ecdsa.h commit f852f4c35bb7e38c70893e229e8e863c6e648d67 Merge: ebfd3ca 93f9919 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Tue Apr 24 10:27:05 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1506' into development-proposed commit ebfd3cad5806d25836d19679f2f2bfc69fdf4b6f Merge: 7aeb470 379b95c Author: Jaeden Amero <jaeden.amero@arm.com> Date: Tue Apr 24 10:26:48 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1505' into development-proposed commit d35340550dea413e5a7ce872561eb84c96179be3 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 23 16:12:42 2018 +0100 Update ecp.h fixed omittion commit c32efb3f641313279a5d75ff7e102ed84e32c899 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 23 09:38:29 2018 +0100 Update ecp.h Resolved last review comment commit d76ac587d3b4eb37548b032d6fd6765575ee9959 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 23 06:29:34 2018 +0100 Update ecp.h Changes based on review comments. Waiting for responses on 2 remaining comments commit abc9ec73b04c9e7f0e3fb3123471c33a973eed36 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 23 06:16:40 2018 +0100 Update ecdsa.h Merged change to MBEDTLS_ERR_ECP_SIG_LEN_MISMATCH from other commit for merging, as requested (lines 282+283). commit 1d3b508b825f0f4fc2e27694fde6aa1c56184f34 Author: Mohammad Azim Khan <Azim.Khan@arm.com> Date: Wed Apr 18 19:35:00 2018 +0100 Same ciphersuite validation in server and client hello commit 5462e028743938c120e35c0a410955bb055f1a4f Author: Andrzej Kurek <andrzej.kurek@arm.com> Date: Fri Apr 20 07:58:53 2018 -0400 ssl_tls: Fix invalid buffer sizes during compression / decompression Adjust information passed to zlib to include already written data. commit f089fa334181d89bdd37a50b933c9568d1426e4d Author: Rose Zadik <rose.zadik@arm.com> Date: Fri Apr 20 10:41:16 2018 +0100 Update ecp.h minor spacing/comment format fixes commit b2e111a288811b7edd4616dda55afd680c6d4195 Author: Rose Zadik <rose.zadik@arm.com> Date: Fri Apr 20 10:13:48 2018 +0100 Update ecp.h Changes based on review comments. 2 comments still open pending decisions commit 5450d1f597fa3c1a763b4257c19e8086fc994d91 Merge: f2b76cd 81021ca Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Apr 19 21:02:40 2018 +0200 Merge branch 'crypto_alt_revision' into development-restricted-proposed commit 81021ca2da964aa34e30fba8ee672ddfbb504722 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Apr 19 20:59:06 2018 +0200 Improve ChangeLog entry commit f2b76cd45cdce0db903bbe7f67aeb492fddd0652 Merge: 7aeb470 94d4997 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Apr 19 17:41:39 2018 +0200 Merge remote-tracking branch 'upstream-restricted/pr/461' into development-restricted-proposed commit 93f9919c26d8a42bc3ead452964b8e5b189b0522 Author: Rose Zadik <rose.zadik@arm.com> Date: Thu Apr 19 14:41:33 2018 +0100 Update cipher.h Fixed typo. commit c441f7490005800065b206dbfaabbabfe54b9fe7 Author: Rose Zadik <rose.zadik@arm.com> Date: Thu Apr 19 14:38:20 2018 +0100 Update cipher.h minor fix commit 4c368e82cc5456303d4f0d0b7e5fd25c6a240b1a Author: Rose Zadik <rose.zadik@arm.com> Date: Thu Apr 19 14:24:11 2018 +0100 Update cipher.h Additional changes based on review comments commit 826f26492008095bfe919784d4c6ae867240f3c8 Author: Rose Zadik <rose.zadik@arm.com> Date: Thu Apr 19 14:01:29 2018 +0100 Update cipher.h Additional changes based on review comments commit f56cb34d609b9c697238c3a8f2c2096ec0b42be6 Author: Rose Zadik <rose.zadik@arm.com> Date: Thu Apr 19 12:49:10 2018 +0100 Update ecp.h Updated based on review comment. One comment remains open (waiting for input) commit 7aeb470f618d0f056cfa33b0dfd232d9a18a7af4 Merge: 64f5adf 11d3cf4 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 18 12:04:26 2018 +0200 Merge remote-tracking branch 'public/pr/1234' into development-proposed * public/pr/1234: Doxygen: don't traverse symbolic links commit 64f5adf9f91dc29f08cf52d8ac2cbf0879d0aea2 Merge: 4acb005 cb12237 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 18 12:02:43 2018 +0200 Merge remote-tracking branch 'public/pr/1380' into development-proposed * public/pr/1380: Update ChangeLog for #1380 Generate RSA keys according to FIPS 186-4 Generate primes according to FIPS 186-4 Avoid small private exponents during RSA key generation commit 4acb0055e38b68e01680c7182588c6812b9fee08 Merge: 66d3968 9464d7b Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 18 12:01:48 2018 +0200 Merge remote-tracking branch 'public/pr/1518' into development-proposed * public/pr/1518: Update platform.h Update platform.h commit 66d396826a7209fc1602eb7276ceecee11a95efa Merge: bb93c04 1a6275a Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 18 12:00:52 2018 +0200 Merge remote-tracking branch 'public/pr/1516' into development-proposed * public/pr/1516: Update sha512.h commit bb93c04aab4c42e01b5bf2c803dff89c82ac0bb7 Merge: b80f04e 6ee22a7 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 18 12:00:34 2018 +0200 Merge remote-tracking branch 'public/pr/1515' into development-proposed * public/pr/1515: Update sha256.h Update sha256.h commit b80f04eb67686e71c09226e80808153688493ae6 Merge: a937733 2e1934a Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 18 16:13:30 2018 +0200 Merge remote-tracking branch 'upstream-public/pr/1514' into development-proposed commit 2e1934ac0c0a5b3a48739faea03b361aad26934b Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 18 16:05:29 2018 +0200 Fix comment formatting to pacify check-names.sh commit a9377336be9c632671df644e98e6d385fc74fb59 Merge: 0392bff 21e2926 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 18 11:58:53 2018 +0200 Merge remote-tracking branch 'public/pr/1513' into development-proposed * public/pr/1513: Update rsa.h Update rsa.h Update rsa.h commit 0392bff1b958b33ae7bf91bbf49feb44f1742c21 Merge: b3a8fe7 f3e4736 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 18 11:57:50 2018 +0200 Merge remote-tracking branch 'public/pr/1512' into development-proposed * public/pr/1512: Update md.h Update md.h commit b3a8fe7285c9219265fb827fd3039868eb15334f Merge: 01d72df 7375b0f Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 18 11:56:49 2018 +0200 Merge remote-tracking branch 'public/pr/1509' into development-proposed * public/pr/1509: Update ecdh.h Update ecdh.h commit 01d72df1132ec4e79e42e18d07e6737d71b3670e Merge: 7153496 f25eb6e Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 18 11:55:30 2018 +0200 Merge remote-tracking branch 'public/pr/1508' into development-proposed * public/pr/1508: Update ctr_drbg.h Update ctr_drbg.h commit 71534963959e24418f905657f3f8f1a60c879277 Merge: c265a25 c138bb7 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 18 11:54:42 2018 +0200 Merge remote-tracking branch 'public/pr/1507' into development-proposed * public/pr/1507: Update cmac.h Update cmac.h commit c265a25f4fa19beb43259043a2401952bcb7652a Merge: 4ca9a45 819d13d Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 18 11:48:10 2018 +0200 Merge remote-tracking branch 'public/pr/1503' into development-proposed * public/pr/1503: Update aes.h Update aes.h commit fa1fe36e08a45902f40d53c81e9d9532a777e2d9 Author: Rose Zadik <rose.zadik@arm.com> Date: Wed Apr 18 10:09:31 2018 +0100 Update dhm.h Minor fix based on review comments commit ee96359d8916617c9f2766f2e7c8e6c7bf473274 Author: Rose Zadik <rose.zadik@arm.com> Date: Wed Apr 18 09:46:12 2018 +0100 Update dhm.h Changes based on review comments commit f13ca9536c80c145e4b96721bb73a21ca8e9f41a Author: Andrzej Kurek <andrzej.kurek@arm.com> Date: Wed Apr 18 04:14:31 2018 -0400 Test suites: print error on failed platform_setup Return encountered errors instead of covering them Fix return value on the broken snprintf implementation commit 379b95ca9b5ca518dcff2b9f0a69702a49c01269 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Apr 17 16:43:00 2018 +0100 Update ccm.h Updated return values for mbedtls_ccm_auth_decrypt(). commit 477dce15bca9e4a20f9e06d4ad71a9a45fa6974f Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Apr 17 16:31:22 2018 +0100 Update ccm.h updated brief desc. commit ec5d416cb2f09642a867d330e7c6b2934c30616e Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Apr 17 15:55:28 2018 +0100 Update ecdsa.h minor fix based on review comments commit 21e2926736dbb834e0822c9a8a0ce3b7c6f353cf Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Apr 17 14:08:56 2018 +0100 Update rsa.h minor change to the file's brief desc. commit f763f2bbc1c92416d12874fd5f14969279036cb0 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Apr 17 11:00:40 2018 +0100 Update dhm.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Reordered tags within documentation blocks so that params and returns are last in block. *p_rng descriptions changed from "parameter" to "context". *Suggest to specify issue for each return code, where multiple failure return codes are listed, or generalize. *Minor improvements to parameter documentation proposed by eng. commit d3c9bfcbeb02fdb89097d33326a6d1efd52c6a73 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Apr 17 10:56:55 2018 +0100 Update ecp.h Reviewed and standardized commit ef8717984218f9a7d62f121ebb69b6c0219585b7 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Apr 17 10:41:48 2018 +0100 Update ccm.h updated failure returns to "A CCM or cipher-specific error code on failure." commit 6ee22a7d524917bd9da1a0abfcf08899b07eec77 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Apr 17 10:38:39 2018 +0100 Update sha256.h Minor fix based on review comments commit 92d66b88aeab09f0828e0d98ede669956c857ad0 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Apr 17 10:36:56 2018 +0100 Update sha1.h Changes based on review comments commit f2ec288bf891cbfea5deb9996ed54f97d46b50a7 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Apr 17 10:27:25 2018 +0100 Update rsa.h Changes based on review comments. commit f3e4736131f1ee9c4e37d9924c1690dd7d0eb222 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 16 16:31:16 2018 +0100 Update md.h Changes based on review comments commit 6a7ebc4c8663c19890f3d57ddaae68ac9c9872aa Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 16 16:11:49 2018 +0100 Update gcm.h minor fix based on review comments commit 14d0d57c512c6286336c40aad2a15d4b32a7a736 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 16 16:09:30 2018 +0100 Update ecdsa.h Minor changes based on review comments commit 7375b0f6c179db8247fe4510cc8c680f4bccf456 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 16 16:04:57 2018 +0100 Update ecdh.h Changs based on review comments commit 05d0e51bb1cdace99da6571967af1c9adc3b74f8 Author: Ron Eldor <Ron.Eldor@arm.com> Date: Mon Apr 16 17:40:04 2018 +0300 Minor modifications for alt support in des and ecp 1. Add 3des context to be allowed for alternative defintion 2. Move some ecp structs, to disallow alternative definition of them, as other modules rely on them commit 9464d7b6e367407c96bbf1000ecc71d854d14ce1 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 16 15:28:35 2018 +0100 Update platform.h Implemented changes based on review comments commit f25eb6eef6b53db98b6afa5f4b8463f27c200a48 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 16 14:51:52 2018 +0100 Update ctr_drbg.h minor changes based on comments commit a282270a10b42fb0d4d109c3e96ccc745f2095cf Author: Andrzej Kurek <andrzej.kurek@arm.com> Date: Mon Apr 16 06:33:28 2018 -0400 Add explicit checks for non-zero result of platform setup in test suites commit c138bb7b052251401e568df4daef69404a727a4c Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 16 11:11:25 2018 +0100 Update cmac.h minor changes based on comments commit b5607bf61d80d08520dd557e2041599940d2f077 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 16 10:34:51 2018 +0100 Update cipher.h minor changes based on comments commit bd9571a01eb29d2be7dab23925de213021f21d0a Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 16 09:45:12 2018 +0100 Update ccm.h minor changes based on comments commit 819d13dfff96df5aa82f38b8e436ae43c26227a0 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Apr 16 09:35:15 2018 +0100 Update aes.h fixed missing multiple returns on mbedtls_aes_setkey_enc commit 32a675f032fdc9ef14cb8c171fb187d42b51c998 Author: Andrzej Kurek <andrzej.kurek@arm.com> Date: Fri Apr 13 06:16:04 2018 -0400 Add conditional platform context creation & usage Add another layer of abstraction before calling platform setup and teardown. commit aca09c70263c0abe3bc99d6d2f73e4fe7c4e0729 Author: Andrzej Kurek <andrzej.kurek@arm.com> Date: Fri Apr 13 05:18:08 2018 -0400 Changelog entry Describing platform teardown and setup calls in test suites commit 1152fa83f99489cd22149594e6e2f5a4e9be0234 Author: Andrzej Kurek <andrzej.kurek@arm.com> Date: Fri Apr 13 05:15:17 2018 -0400 Add platform setup and teardown calls to test suites Add a global platform context variable available for tests commit cb122373f0f22ae520e6f28cb0fddc023b6f293e Author: Jethro Beekman <jethro@fortanix.com> Date: Wed Apr 11 08:40:38 2018 -0700 Update ChangeLog for #1380 commit c645bfe176aa4ab8c7a6a28ad44565c039392cce Author: Jethro Beekman <jethro@fortanix.com> Date: Wed Feb 14 19:27:13 2018 -0800 Generate RSA keys according to FIPS 186-4 The specification requires that P and Q are not too close. The specification also requires that you generate a P and stick with it, generating new Qs until you have found a pair that works. In practice, it turns out that sometimes a particular P results in it being very unlikely a Q can be found matching all the constraints. So we keep the original behavior where a new P and Q are generated every round. commit 666892792d98d68f45aac0e3ff3cfda2baa89a57 Author: Jethro Beekman <jethro@fortanix.com> Date: Wed Feb 14 19:24:10 2018 -0800 Generate primes according to FIPS 186-4 The specification requires that numbers are the raw entropy (except for odd/ even) and at least 2^(nbits-0.5). If not, new random bits need to be used for the next number. Similarly, if the number is not prime new random bits need to be used. commit 97f95c9ef3668b762e499907da872e942a8d3b7f Author: Jethro Beekman <jethro@fortanix.com> Date: Tue Feb 13 15:50:36 2018 -0800 Avoid small private exponents during RSA key generation Attacks against RSA exist for small D. [Wiener] established this for D < N^0.25. [Boneh] suggests the bound should be N^0.5. Multiple possible values of D might exist for the same set of E, P, Q. The attack works when there exists any possible D that is small. To make sure that the generated key is not susceptible to attack, we need to make sure we have found the smallest possible D, and then check that D is big enough. The Carmichael function λ of p*q is lcm(p-1, q-1), so we can apply Carmichael's theorem to show that D = d mod λ(n) is the smallest. [Wiener] Michael J. Wiener, "Cryptanalysis of Short RSA Secret Exponents" [Boneh] Dan Boneh and Glenn Durfee, "Cryptanalysis of RSA with Private Key d Less than N^0.292" commit 4ca9a457561fc774ca54898a72754bf53d60dba2 Merge: e72d322 5053efd Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 11 13:06:30 2018 +0200 Merge remote-tracking branch 'public/pr/1560' into development-proposed * public/pr/1560: Warn if using a memory sanitizer on AESNI commit e72d3225a742362563b07c2d6c763981a2b67cf8 Merge: 80aa3b8 ec4733b Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Apr 11 13:05:31 2018 +0200 Merge remote-tracking branch 'public/pr/1559' into development-proposed * public/pr/1559: Make the memset call prior to FD_ZERO conditional to needing it commit bf027e736a64af33307f15a5d1bd5c491c9b822e Author: Ron Eldor <Ron.Eldor@arm.com> Date: Mon Apr 9 15:51:19 2018 +0300 Minor modifications after PR review 1. Move ChangLog entry to correct location 2. Move point formats outside the ECP_ALT check, as it's part of the RFC commit 5053efde33ef1777b8791e4b34338fb13a66c663 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Apr 5 15:25:50 2018 +0200 Warn if using a memory sanitizer on AESNI Clang-Msan is known to report spurious errors when MBEDTLS_AESNI_C is enabled, due to the use of assembly code. The error reports don't mention AES, so they can be difficult to trace back to the use of AES-NI. Warn about this potential problem at compile time. commit ec4733b645f8a3402c4e4adf454dab5ae565126a Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Apr 5 14:55:47 2018 +0200 Make the memset call prior to FD_ZERO conditional to needing it Zeroing out an fd_set before calling FD_ZERO on it is in principle useless, but without it some memory sanitizers think the fd_set is still uninitialized after FD_ZERO (e.g. clang-msan/Glibc/x86_64 where FD_ZERO is implemented in assembly). Make the zeroing conditional on using a memory sanitizer. commit 94d49978eb8ac94f97c8c5f15aad9d45fe30efc1 Author: Krzysztof Stachowiak <krzysztof.stachowiak@arm.com> Date: Thu Apr 5 14:48:55 2018 +0200 Improve comments style commit cd09fc812dcbfbee63e69f243381d7d0343fc54c Author: Krzysztof Stachowiak <krzysztof.stachowiak@arm.com> Date: Thu Apr 5 14:48:18 2018 +0200 Remove a redundant test commit 73b183c3bb6e729bcd3b47804de52fdc9194940c Author: Krzysztof Stachowiak <krzysztof.stachowiak@arm.com> Date: Thu Apr 5 10:20:09 2018 +0200 Add buffer size check before cert_type_len read commit 80aa3b8d6509be24cb67454e7a0519da20951faf Merge: 5c77f2e e4d3b7f Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 4 10:33:45 2018 +0200 Merge branch 'pr_946' into development-proposed commit 5c77f2ef377fac3ad979a0ea1d9e41e40852804a Merge: b9e8696 19d1373 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 4 10:31:09 2018 +0200 Merge remote-tracking branch 'upstream-public/pr/1535' into development-proposed commit e4d3b7f86074e32d907867d72ee52507b47b3457 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 4 09:28:48 2018 +0200 Fix merge glitch in ChangeLog commit b9e8696d56ce7326d3121a71314cf3570f764fca Merge: 315b460 b364053 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 4 09:20:59 2018 +0200 Merge remote-tracking branch 'upstream-public/pr/1142' into development-proposed commit 315b460593fb451d71a9ff99cfca6aba546e0aeb Merge: 73db838 a4cbfa3 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 4 09:19:27 2018 +0200 Merge remote-tracking branch 'upstream-public/pr/1457' into development-proposed commit 73db8380cae7e16d284d6f66b60630bc6e0dab6e Merge: be2371c c96ccf4 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 4 09:19:12 2018 +0200 Merge remote-tracking branch 'upstream-public/pr/1547' into development-proposed commit be2371c3d960ea9f7376b801765125f328a36d09 Merge: a09453f 557e77d Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 4 09:18:27 2018 +0200 Merge branch 'pr_348' into development-proposed commit 557e77d9a31c5bad6930dde800ba46939151a834 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 4 09:18:11 2018 +0200 Add ChangeLog entry commit a09453f495d067feb6b85f2df9400dc732a1eb78 Merge: 1fae860 d6953b5 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 4 09:14:12 2018 +0200 Merge branch 'pr_1395' into development-proposed commit d6953b58d74fb721edf71c825355d76d93b64129 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 4 09:09:29 2018 +0200 Improve changelog entry commit 1fae860f0f02a5fe9f966c8d7d4b96d62985f6c2 Merge: 90a8b52 cc78ac4 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Apr 4 09:03:25 2018 +0200 Merge remote-tracking branch 'upstream-public/pr/1543' into development-proposed commit f4e5b7e87de2484f0e3dbb9d11e87dd275874cd0 Author: Hanno Becker <hanno.becker@arm.com> Date: Tue Apr 3 16:28:09 2018 +0100 Additionally initialize fd_set's via memset in mbedtls_net_poll The initialization via FD_SET is not seen by memory sanitizers if FD_SET is implemented through assembly. Additionally zeroizing the respective fd_set's before calling FD_SET contents the sanitizers and comes at a negligible computational overhead. commit b364053a8718bb76e364dfe3df01e0f4d3eab97a Author: Andrzej Kurek <andrzej.kurek@arm.com> Date: Tue Apr 3 06:16:04 2018 -0400 pk_sign: add stdlib include commit 0cbe816bfc8ba361d25920d09114eb8bc3ffb99a Author: Kevin Luty <kevin.charles.luty@jci.com> Date: Mon Apr 2 10:01:16 2018 -0500 ChangeLog updated and returning proper value commit 19d392b2581d1bded5ba61051b8b6343c0511b78 Author: mohammad1603 <mohammad.abomokh@arm.com> Date: Mon Apr 2 07:25:26 2018 -0700 Fix compatibility problem in the printed message Replace %zu with %lu and add cast for the printed value. commit 810e650c707f9bce7d5eb679f2f5ecc85b32abc3 Author: Ron Eldor <Ron.Eldor@arm.com> Date: Sun Apr 1 15:59:58 2018 +0300 Adjust more modules to new design Add `ecp.h` anf `timing.h` to new XXX_alt design commit 1c9f9be9a29b7b4d02b17877702369132515c9ed Author: Ron Eldor <Ron.Eldor@arm.com> Date: Wed Feb 7 16:40:17 2018 +0200 update ChangeLog Update ChangeLog with suggested rephrasing commit 4e6d55d14d1156c20f184640d9b259402da579f5 Author: Ron Eldor <Ron.Eldor@arm.com> Date: Wed Feb 7 16:36:15 2018 +0200 Add new modules to the refactoring Add new alternative supported modules to the new arcitecture design commit b2aacec417d74f68d1eb01581e353b6623df706e Author: Ron Eldor <Ron.Eldor@arm.com> Date: Thu May 18 16:53:08 2017 +0300 Take Cryptographic API outside the XXX_ALT check The cryptographic API should not be related to whether or not there is alternative implementation. The API should be same for regular implementation, and for alternative implementation, so it is defined outside of the XXX_ALT precompilation check in the cryptographic API header commit 90a8b5219f13d3b6b35128a9ee5565adf84b2e70 Merge: 0ed632f 092bf3d Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Sun Apr 1 12:44:06 2018 +0200 Merge branch 'pr_1480' into development-proposed commit 092bf3dd3898e67b9dff2bb5d4f2aa289a827135 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Sun Apr 1 12:43:48 2018 +0200 Add original PR reference commit 0ed632f44594cfb16c003fd1f2784a8155edb7bb Merge: 5e4464e 79db933 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Sun Apr 1 12:41:22 2018 +0200 Merge remote-tracking branch 'upstream-public/pr/1499' into development-proposed commit 5e4464e3929b6db630a569d692d120db30b9d7fa Merge: 695d557 eea1c4e Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Sun Apr 1 12:40:37 2018 +0200 Merge remote-tracking branch 'upstream-public/pr/1539' into development-proposed commit 695d557dcf91cb88c8469933765a2a12be98cc06 Merge: 4ba87fc 4045c74 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Sun Apr 1 12:26:36 2018 +0200 Merge branch 'pr_1180' into development-proposed commit 4045c7442189b42157f1a8e885a33db87d33ad89 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Sun Apr 1 12:25:48 2018 +0200 Minor changelog improvement commit c96ccf4b3f2fc0c1336390cae25e4852d4d3411a Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Sat Mar 31 22:57:03 2018 +0200 Add ChangeLog entry to credit independent contribution Also: fixes #1437 commit 039fd128349e3f19d80aa60ea228a2498a8fbc44 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Mon Mar 19 19:06:08 2018 +0100 Robustness fix in mbedtls_ssl_derive_keys In mbedtls_ssl_derive_keys, don't call mbedtls_md_hmac_starts in ciphersuites that don't use HMAC. This doesn't change the behavior of the code, but avoids relying on an uncaught error when attempting to start an HMAC operation that hadn't been initialized. commit cc78ac46e79d5c5ea6850c9f56483ea94a2a646b Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Fri Mar 30 18:52:10 2018 +0200 Update error.c commit 5114d3e4e1cb6e5a71ceafa56dd7da5f9182f9d9 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Fri Mar 30 07:12:15 2018 +0200 Clarify the use of MBEDTLS_ERR_PK_SIG_LEN_MISMATCH Clarify what MBEDTLS_ERR_ECP_SIG_LEN_MISMATCH and MBEDTLS_ERR_PK_SIG_LEN_MISMATCH mean. Add comments to highlight that this indicates that a valid signature is present, unlike other error codes. See https://github.com/ARMmbed/mbedtls/pull/1149#discussion_r178130705 commit eea1c4ee5a054c77c901d5dafc560483101c4fe8 Author: Darryl Green <darryl.green@arm.com> Date: Thu Mar 29 16:05:44 2018 +0100 Improve documentation of mbedtls_ssl_write() commit 08f3ef1861478587211971494541a6b0e97cfdc7 Author: Nicholas Wilson <nicholas.wilson@realvnc.com> Date: Tue Nov 10 13:10:01 2015 +0000 Basic support for Curve448, similar to the current level of support for Curve25519 commit a357f1a6caa11703bc63459af17bdac05277572d Author: Andrzej Kurek <andrzej.kurek@arm.com> Date: Thu Mar 29 08:17:15 2018 -0400 Move changelog entry to bugfix from changes commit 19d1373bb9d4cf581b65b4b82306bcd73e4a3242 Author: Azim Khan <Azim.Khan@arm.com> Date: Thu Mar 29 11:04:20 2018 +0100 Enable SSL test scripts to dump logs on stdout commit 4ba87fc958cf267fe175c2323ce631e40b17ae7f Merge: 2ad47e3 065ecf5 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Thu Mar 29 11:01:38 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/758' into development-proposed commit 2ad47e3bccc2985557b04409a1369bd2e7ff0d1b Merge: 78a03ec 18b7843 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Thu Mar 29 11:00:50 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1528' into development-proposed commit 78a03ec2308bf0926c9d8c0cce9f545a2b4b2641 Merge: 5031a9a d2df936 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Thu Mar 29 10:57:57 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1379' into development-proposed commit 5031a9a278697863ac1f493372764dc8162d333e Merge: 90226be 69944b1 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Thu Mar 29 10:53:42 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1134' into development-proposed Fixes #504 and fixes #1057 commit 52aecb9a7f57b63e56a8adde7baf75c9b60f5050 Author: mohammad1603 <mohammad.abomokh@arm.com> Date: Wed Mar 28 23:41:40 2018 -0700 Check whether INT_MAX larger than SIZE_MAX scenario Check whether INT_MAX larger than SIZE_MAX scenario commit 90226be77957608b89f409ad851c4e79c46849a1 Merge: 2843d21 8e0e160 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 28 15:35:22 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1467' into development-proposed commit 2843d21d9989a02bd29837873b00de6c32836c28 Merge: 5ec1183 cb47a79 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 28 15:32:13 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1523' into development-proposed commit 2bd57578afff890b10075b46609e640a335a6b48 Merge: ea7dbbe b604960 Author: Hanno Becker <hanno.becker@arm.com> Date: Wed Mar 28 14:52:35 2018 +0100 Merge branch 'development' into iotssl-1204 commit 5ec118352e3a03c2ecbf6eb856b08577e2189a03 Merge: 552b9cc 7183031 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 28 14:22:29 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1474' into development-proposed commit 065ecf587f3bf1fc59df46e4e1c1adb01074c1b8 Author: Ivan Krylov <krylov.r00t@gmail.com> Date: Wed Mar 28 16:19:18 2018 +0300 Changelog: use my real name (#758) commit 552b9cc5bac8cbd7b39923c8ef20d43fdecc9820 Merge: 9528658 768bbaf Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 28 13:42:32 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1477' into development-proposed commit 9528658446fff652fbfe76b67190a08967544e9f Merge: 8645e90 f69ad5a Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 28 12:50:28 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/701' into development-proposed Fixes #1299, fixes #1475 commit 8645e908255694e8d3c3f1c04b439cc66cdd35a3 Merge: b604960 6a92ce6 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 28 11:54:28 2018 +0100 Merge remote-tracking branch 'upstream-restricted/pr/363' into development-proposed commit 6a92ce6fd96a97f53483d48a7a475952d203a1f1 Author: Hanno Becker <hanno.becker@arm.com> Date: Wed Mar 28 11:42:05 2018 +0100 Improve documentation of MBEDTLS_AES_FEWER_TABLES in config.h commit 18b78435dc3883ad0aae000662a28f74ccfd7375 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Mar 28 11:14:06 2018 +0200 Fix a typo in a comment commit fff308e2faa9d3ae489bd8c285162267bb05d570 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Mar 28 11:13:05 2018 +0200 Add a ChangeLog entry for Curve22519 N commit 54fc34ea683167260ec5df3dc94a7c544b08325c Author: Nicholas Wilson <nicholas.wilson@realvnc.com> Date: Mon May 16 15:15:45 2016 +0100 Include order of Curve25519 base point in curve data commit 71830318d3e9000395d6178fbb0c6d0088b2f73e Author: Azim Khan <Azim.Khan@arm.com> Date: Wed Mar 28 09:48:29 2018 +0100 Rephrase Changelog entry Bugfix->Changes commit 6c563fa7cd97a2d4af5424bc562c591ec55758a5 Author: Jethro Beekman <jethro@fortanix.com> Date: Tue Mar 27 19:16:17 2018 -0700 Add tests for "return plaintext data faster on unpadded decryption" commit f69ad5a898fae494992d974f4f3a245ea3e30afd Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Tue Mar 27 23:08:53 2018 +0200 Add ChangeLog entry Fixes #1299. Fixes #1475. commit cb47a79e0422c3cda9c3915076dc4a11fa756acf Author: Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> Date: Tue Mar 27 21:19:50 2018 +0100 Add ChangeLog entry for PBES2 when ASN1 disabled commit 576d47470468759739fd086a026208eb294892cb Author: Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> Date: Tue Mar 27 20:53:56 2018 +0100 Fix test dependencies of pkcs5 pbs2 on asn1 parse commit af9a486b0138709bea86b53c116faa457d96754f Author: Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> Date: Tue Mar 27 20:53:07 2018 +0100 Fix coding style in pkcs5.c preprocessor directives commit 8a0dfacb58d7a3600f66b319bdc0661fb19ad5a9 Author: Marcos Del Sol Vives <marcos@dracon.es> Date: Sun Nov 6 12:22:25 2016 +0100 Compile PBES2 in PKCS5 only if ASN1 is enabled commit 79db933fb605e5d3594a42c162b7a6eb9f3de3a7 Author: Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> Date: Tue Mar 27 19:57:58 2018 +0100 Fix shared library lookup on Mac OS X when running tests commit 420f0ccdfd97fdba2047c3f219a3dfbdc5c2f6a0 Author: Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> Date: Tue Mar 27 19:17:21 2018 +0100 Make DLEXT var configurable in programs and tests makefiles commit d1b1788b40ef8dd5e3393a32eea439a68f9fc6a1 Author: Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> Date: Tue Mar 27 19:14:24 2018 +0100 Improve ChangeLog for DLEXT and AR_DASH changes commit 79e7789d4468ab12ee3ff4acdc3a9e7fe4238db0 Author: Andy Leiserson <andy@fortanix.com> Date: Fri Apr 28 20:01:49 2017 -0700 return plaintext data faster on unpadded decryption commit 98a678674bb8e922de057c3652f2173ca0372605 Author: Hanno Becker <hanno.becker@arm.com> Date: Tue Mar 27 17:10:09 2018 +0100 Adapt changes to all.sh to work with --keep-going mode commit 4c1dc3c2a4144696752091116c86279e24f148dd Author: Hanno Becker <hanno.becker@arm.com> Date: Tue Mar 27 16:52:03 2018 +0100 Improve documentation of MBEDTLS_AES_ROM_TABLES commit 783cb06e051b2d3f992147b1fbc8d103cbb80286 Author: Hanno Becker <hanno.becker@arm.com> Date: Tue Mar 27 16:49:04 2018 +0100 Remove duplicate test in all.sh commit b60496057256e435eda8de2f2653d920e4f46207 Merge: fba16f7 d49ab3e Author: Jaeden Amero <jaeden.amero@arm.com> Date: Mon Mar 26 18:25:58 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1435' into development-proposed commit fba16f782c5553166322b3cc7f0391d0cd187b73 Merge: f65379b 3f21a35 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Mon Mar 26 18:22:34 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/572' into development-proposed commit de420a47b63d838403f029b80b9490e574300fad Author: Deomid Ryabkov <rojer@cesanta.com> Date: Sun Nov 27 14:50:06 2016 +0000 Fix some test deps * Cert revocation tests require `MBEDTLS_HAVE_TIME_DATE`. * Verison features tests require... well, `MBEDTLS_VERSION_FEATURES`, actually. Fixes https://github.com/ARMmbed/mbedtls/issues/1475 commit 4bca2b0ccd33a8c31b691d7514ee18e6e9d4acca Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Mar 27 13:12:52 2018 +0100 Update platform.h Minor documentation improvements: *Standardized file brief description. *Reordered tags within documentation blocks so that params and returns are last in block. *Some minor rephrasing. commit 1a6275ad6269c4c511a31c62da2fe5f9b217ec2e Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Mar 27 13:03:42 2018 +0100 Update sha512.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Removed bullets from parameter descriptions. commit bde68b48d4a4754096bf6ddf873c2a363db182b1 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Mar 27 12:59:13 2018 +0100 Update sha256.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Reordered tags within documentation blocks so that params and returns are last in block. *Removed bullets from parameter descriptions. commit 8274142e45bb14a116a55f11388c099c3981b91f Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Mar 27 12:49:48 2018 +0100 Update sha1.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Reordered tags within documentation blocks so that params and returns are last in block. *Applied previous function documentation improvements to depracated functions. commit e8b5b99159bb6da2ce5bf88769758ea6c155bf42 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Mar 27 12:19:47 2018 +0100 Update rsa.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Reordered tags within documentation blocks so that params and returns are last in block. *p_rng descriptions changed from "parameter" to "context". commit 8c9c794518d27ef538308493666557a4807b7f74 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Mar 27 11:52:58 2018 +0100 Update md.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Reordered tags within documentation blocks so that params and returns are last in block. commit d8c4f61d266a70e07f8fe2a7e51aa967e324aa19 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Mar 27 11:43:04 2018 +0100 Update gcm.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Reordered tags within documentation blocks so that params and returns are last in block. *Suggest to specify issue for each return code, where multiple failure return codes are listed. commit 817297fcd73e214cd5079d970725d1d4a9462b58 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Mar 27 11:30:14 2018 +0100 Update ecdsa.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Reordered tags within documentation blocks so that params and returns are last in block. *p_rng descriptions changed from "parameter" to "context". commit 6899328bf85fa6d89814d8df73b9e20cc96cd0a2 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Mar 27 11:12:25 2018 +0100 Update ecdh.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Reordered tags within documentation blocks so that params and returns are last in block. *p_rng descriptions changed from "parameter" to "context". *Removed bullets from parameter descriptions. commit c9474ebdbb4e42d2411220cf3a50306703be5e0d Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Mar 27 10:58:22 2018 +0100 Update ctr_drbg.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Reordered tags within documentation blocks so that params and returns are last in block. *Suggest to specify issue for each return code, where multiple failure return codes are listed. commit 8c154935f6d0a5630b03cce267db298054aa00af Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Mar 27 10:45:16 2018 +0100 Update cmac.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Please verify RFC in file description. commit 02facfb4d9a176f68bdaf8251160e52bf85a8258 Author: Rose Zadik <rose.zadik@arm.com> Date: Tue Mar 27 10:26:56 2018 +0100 Update cipher.h commit f4659efedcb5a0d2e77dc1617f5ba8c26cd5d6e0 Author: Azim Khan <Azim.Khan@arm.com> Date: Mon Mar 26 22:11:24 2018 +0100 Document config restrictions of psk fields commit 02f73a6b555c7784bd90ef25baecb4dbc3528c17 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Mar 26 18:02:32 2018 +0100 Update cipher.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Reordered tags within documentation blocks so that params and returns are last in block. *Added missing documentation in lines 99-159 (values in enums) - need to be verified. *lines 79+80 and 97+98 - verify descriptions + what is the difference here between none and null? *lines 177-187 - seems to be an enum without a name? commit 4ee9d24c904cab2c3540bf9f240efe768bd11703 Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Mar 26 17:18:44 2018 +0100 Update ccm.h Minor documentation improvements: *Standardized file brief description. *Separated return statements. *Reordered tags within documentation blocks so that params and returns are last in block. commit 5ad7aea5688081a6217b9f491befb521f37ee71b Author: Rose Zadik <rose.zadik@arm.com> Date: Mon Mar 26 12:00:09 2018 +0100 Update aes.h Minor documentation improvements: Standardized brief file description. Split returns. Minor fixes. commit e4f2736b42656bc62e3e48faf79f91140ab83ce8 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Mon Mar 26 12:29:30 2018 +0200 Add ChangeLog entry commit ea5a8a418b4fe4b463a5cc0a08e2193a38105950 Author: Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> Date: Sun Mar 25 23:57:09 2018 +0100 Add ChangeLog entry for library/makefile changes commit ceed91b72c307d6aa27afb770e38786d27651b96 Author: Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> Date: Sun Mar 25 23:48:39 2018 +0100 Allow overriding ar param prefix in library/Makefile commit 873f15d70d4bbdefa87c847bfe36b183320a8872 Author: Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> Date: Sun Mar 25 23:47:15 2018 +0100 Make DLEXT var configurable in library/Makefile commit 5cb1f09ab46ea19e1df78af86fbb19f3de6f8ef4 Author: Ivan Krylov <krylov.r00t@gmail.com> Date: Sat Mar 24 18:48:04 2018 +0300 slight rewording requested by reviewer (#758) commit f65379bc400707baac9466cce88a759685ac6c01 Merge: fc458d0 51d9394 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Fri Mar 23 11:14:17 2018 +0000 Merge remote-tracking branch 'upstream-restricted/pr/382' into development commit 51d9394fdf93c24615cb41f36eeb9bbfe17ed72d Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Fri Mar 23 01:42:44 2018 +0100 Add changelog entries for improved testing Fixes #1040 commit 1cfa2d0e198e2b45c7b63d774dee119189643076 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Fri Mar 23 00:55:57 2018 +0100 Add missing dependencies in test_suite_x509parse Found by depends-hashes.pl and depends-pkgalgs.pl. commit 396fac1fe01bed0d9f77389f8c29f7484a041cee Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Mar 22 22:26:03 2018 +0100 all.sh --keep-going: properly handle multiple-builds scripts In keep-going mode, if a multiple-builds script fails, record its status and keep going. commit 15ad57989598007a8d401d927052ac65df27efd4 Merge: 1ba8a3f 8be0e6d Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Mar 22 22:21:55 2018 +0100 Merge tag 'mbedtls-2.8.0' into iotssl-1381-x509-verify-refactor-restricted Conflict resolution: * ChangeLog * tests/data_files/Makefile: concurrent additions, order irrelevant * tests/data_files/test-ca.opensslconf: concurrent additions, order irrelevant * tests/scripts/all.sh: one comment change conflicted with a code addition. In addition some of the additions in the iotssl-1381-x509-verify-refactor-restricted branch need support for keep-going mode, this will be added in a subsequent commit. commit d2df936e67e395e5f9ab0bcf059a8c0040f0a6da Author: Jethro Beekman <jethro@fortanix.com> Date: Fri Feb 16 13:11:04 2018 -0800 Fix parsing of PKCS#8 encoded Elliptic Curve keys. The relevant ASN.1 definitions for a PKCS#8 encoded Elliptic Curve key are: PrivateKeyInfo ::= SEQUENCE { version Version, privateKeyAlgorithm PrivateKeyAlgorithmIdentifier, privateKey PrivateKey, attributes [0] IMPLICIT Attributes OPTIONAL } AlgorithmIdentifier ::= SEQUENCE { algorithm OBJECT IDENTIFIER, parameters ANY DEFINED BY algorithm OPTIONAL } ECParameters ::= CHOICE { namedCurve OBJECT IDENTIFIER -- implicitCurve NULL -- specifiedCurve SpecifiedECDomain } ECPrivateKey ::= SEQUENCE { version INTEGER { ecPrivkeyVer1(1) } (ecPrivkeyVer1), privateKey OCTET STRING, parameters [0] ECParameters {{ NamedCurve }} OPTIONAL, publicKey [1] BIT STRING OPTIONAL } Because of the two optional fields, there are 4 possible variants that need to be parsed: no optional fields, only parameters, only public key, and both optional fields. Previously mbedTLS was unable to parse keys with "only parameters". Also, only "only public key" was tested. There was a test for "no optional fields", but it was labelled incorrectly as SEC.1 and not run because of a great renaming mixup. commit fc458d0b9bbfe5e0cd6335eb083b7c15958a2610 Merge: a7b34c7 9b9cc61 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Mar 22 21:53:12 2018 +0100 Merge remote-tracking branch 'myfork/pr_1073' into development-proposed commit a7b34c78101ed21b1dfd7e85a687010f66058ca6 Merge: f15a8be 060fe37 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Mar 22 21:52:48 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1406' into development-proposed commit f15a8beacf47c823d38fd2e5c47513b1375e9ad2 Merge: 0818540 4e5d23f Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Mar 22 21:51:53 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1256' into development-proposed commit 0818540ff7aed91bcf217431e5c7ff7cce72d576 Merge: 5bdb671 88c6df1 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Mar 22 21:50:48 2018 +0100 Merge branch 'pr_726' into development-proposed commit 88c6df1ce8cb5b553e1f8f1f24c41b473a73db03 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Mar 22 21:48:28 2018 +0100 Add ChangeLog entry commit 5bdb671404b3335d8f42cdfdccf8d4de26d4b80e Merge: 4b6b247 58afc39 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Mar 22 21:34:15 2018 +0100 Merge branch 'pr_403' into development-proposed commit 58afc39dd701280d84643f8699e88d5e8d2be1c9 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Mar 22 21:33:28 2018 +0100 Add ChangeLog entry commit 4b6b2475124f275270a16f93a366fc0b04efa3ba Merge: 8be0e6d ccbd8a4 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Mar 22 21:30:07 2018 +0100 Merge remote-tracking branch 'upstream-public/pr/1441' into development-proposed commit 9b9cc616ca13b23f76e10726e19ffa463ce3cb92 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Mar 22 17:03:45 2018 +0100 Add ChangeLog entry commit d9d5c554382306b9b9f856746d253c2e3b742ea2 Author: Kevin Luty <kevin.charles.luty@jci.com> Date: Thu Mar 22 09:56:26 2018 -0500 Assign error return value for failed write commit bdfc14e4a3a4538ccffc8f09313cbbd70ea14669 Author: Azim Khan <Azim.Khan@arm.com> Date: Thu Mar 22 12:17:36 2018 +0000 Add reference to original PR in Changelog commit 4d58881f521ed5e4fbcbda1d33aadc59c44432fa Author: Azim Khan <Azim.Khan@arm.com> Date: Thu Mar 22 12:04:25 2018 +0000 Clarify bug scenario in Changlog commit bc30c5fec289ec3c10508a759e4f6a9cbaaeb05b Author: Azim Khan <Azim.Khan@arm.com> Date: Thu Mar 22 10:24:06 2018 +0000 Add change log entry for mbedtls_ssl_config_free() fix commit b8788059196c901a263d4dc510c737fd009e47a4 Author: mohammad1603 <mohammad.abomokh@arm.com> Date: Thu Mar 22 02:40:43 2018 -0700 Verify that f_send and f_recv send and receive the expected length Verify that f_send and f_recv send and receive the expected length commit 768bbaf0c183f26377d7a06086a494d1fe98c408 Author: Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> Date: Wed Mar 21 15:05:12 2018 +0000 Add ChangeLog entry for redundant mutex initialization optimizations commit d49ab3ee60290b00f952e9d1aca364385c0d6e78 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Mar 21 17:03:44 2018 +0100 Add ChangeLog entry. Fixes #1353 commit 4e4be7cf623803865d4259f6c3a11414b6565221 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Mar 21 16:29:03 2018 +0100 Optimize unnecessary zeorizing in mbedtls_mpi_copy Based on a contribution by Alexey Skalozub (https://github.com/ARMmbed/mbedtls/pull/405). commit 70ad8397259f96f53104929b0c416f6617280b69 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Wed Mar 21 16:28:41 2018 +0100 Clarify the behavior of bignum resize and copy functions commit 13f7fb372e3a03a13f797489c13a1ec218678ec0 Author: Gergely Budai <gbudai76@gmail.com> Date: Wed Aug 23 14:23:58 2017 +0200 Do not define and initialize global mutexes on configurations that do not use them. commit 1e7059fedd6d397f1ee09f5d0bb53c2148b5d6e0 Author: Kevin Luty <kevin.charles.luty@jci.com> Date: Wed Mar 21 10:01:38 2018 -0500 Adding requested changes commit 27e8a120b2401dbe9d8aec479d7a203cb3143398 Author: Azim Khan <Azim.Khan@arm.com> Date: Wed Mar 21 14:24:11 2018 +0000 Assign NULL after freeing psk and psk_identity commit 316b162ac34456bb36e7f8cef37bd6a50f191048 Author: junyeonLEE <dlwnsdus2@naver.com> Date: Wed Dec 20 16:29:30 2017 +0900 Separate psk and psk_identity buffers free Sometimes, psk_identity buffer can't released because psk buffer is NULL. So, separate it. commit 8e0e16032d6dc4f0ff8f72a0a3f2eb6e1153710c Author: Andres Amaya Garcia <Andres.AmayaGarcia@arm.com> Date: Wed Mar 21 11:15:08 2018 +0000 Add ChangeLog entry for dylib builds using Makefile commit 5ff2ee51e9d9a2be2294b447021a0d2ef0f0fc1d Author: Mitsuhiro Nakamura <m.nacamura@gmail.com> Date: Tue Feb 20 11:58:19 2018 +0900 Fix dylib linking commit c0b13f7f0c845b1ef348dd82e0f5790e6c07ebc9 Author: Krzysztof Stachowiak <krzysiek.stachowiak@gmail.com> Date: Tue Mar 20 14:10:15 2018 +0100 Update change log commit bc231cc9b0cecf9723e9e12a6de2cc78f847e1b6 Author: Krzysztof Stachowiak <krzysiek.stachowiak@gmail.com> Date: Tue Mar 20 14:09:53 2018 +0100 Add a missing buffer size check commit bc145f797843a75756bfe0a0328d249e0a769cb5 Author: Krzysztof Stachowiak <krzysiek.stachowiak@gmail.com> Date: Tue Mar 20 11:19:50 2018 +0100 Correct buffer size check Further in the code the next field from the binary buffer is read. The check contained an off by one error. commit ea7dbbe0de008c1844f8f48fde08542e6a222fcc Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Thu Mar 15 23:25:21 2018 +0100 Replace MBEDTLS_EINTR by IS_EINTR check-names.sh reserves the prefix MBEDTLS_ for macros defined in config.h so this name (or check-names.sh) had to change. This is also more flexible because it allows for platforms that don't have an EINTR equivalent or have multiple such values. commit c9f4d6d44899a26f001c28b93e86cf7d6452e693 Author: Hanno Becker <hanno.becker@arm.com> Date: Mon Mar 19 09:23:13 2018 +0000 Correct error.c commit 8be0e6db41b4a085e90cb03983f99d3a5158d450 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Fri Mar 16 16:25:12 2018 +0000 Update version to 2.8.0 commit a4cbfa3ea2a0b19b77a0639630fa99fac22b3793 Author: Simon Butcher <simon.butcher@arm.com> Date: Fri Mar 16 15:42:54 2018 +0000 Add clarity to use of the rsa_internal.h interface Added additional clarification to the use of the rsa_internal.h interface and as and when it can be used by whom. Policy hasn't changed, but it needed to be clearer who can and can't use it and it's level of support. commit ef52796537c89bfb06d4eb5daecab7d013a57749 Author: Hanno Becker <hanno.becker@arm.com> Date: Thu Mar 15 15:49:24 2018 +0000 Fix missing return statement ssl_server2 idling Also, introduce MBEDTLS_EINTR locally in net_sockets.c for the platform-dependent return code macro used by the `select` call to indicate that the poll was interrupted by a signal handler: On Unix, the corresponding macro is EINTR, while on Windows, it's WSAEINTR. commit 80e06d77d95329c1a43e7d9dba73e289bdeec1ec Author: Hanno Becker <hanno.becker@arm.com> Date: Thu Mar 15 14:41:55 2018 +0000 Use WSAEINTR instead of EINTR on Windows commit 9b2b66ebd250e63e51c87d9b75fd67bad4e1e8f9 Author: Hanno Becker <hanno.becker@arm.com> Date: Thu Mar 15 12:21:15 2018 +0000 Minor style corrections Move function block brace outside conditional compilation to not confuse some editors, and correct indentation. commit 9ac640326b5ec7bf1140cc542a91b61d10ba2d51 Author: Hanno Becker <hanno.becker@arm.com> Date: Thu Mar 15 12:19:31 2018 +0000 Don't exit mbedtls_net_poll on interruption of select If the select UNIX system call is interrupted by a signal handler, it is not automatically restarted but returns EINTR. This commit modifies the use of select in mbedtls_net_poll from net_sockets.c to retry the select call in this case. commit adfa64f0c4d99db9cf08ad927843c564209e8506 Author: Hanno Becker <hanno.becker@arm.com> Date: Thu Mar 15 11:35:07 2018 +0000 Abort idle-loop in ssl_server2 if sockets gets invalid Previously, the idling loop in ssl_server2 didn't check whether the underlying call to mbedtls_net_poll signalled that the socket became invalid. This had the consequence that during idling, the server couldn't be terminated through a SIGTERM, as the corresponding handler would only close the sockets and expect the remainder of the program to shutdown gracefully as a consequence of this. This was subsequently attempted to be fixed through a change in ssl-opt.sh by terminating the server through a KILL signal, which however lead to other problems when the latter was run under valgrind. This commit changes the idling loop in ssl_server2 and ssl_client2 to obey the return code of mbedtls_net_poll and gracefully shutdown if an error occurs, e.g. because the socket was closed. As a consequence, the server termination via a KILL signal in ssl-opt.sh is no longer necessary, with the previous `kill; wait` pattern being sufficient. The commit reverts the corresponding change. commit 8d83218b702e78e1b403a8a3c2bb0abd9bd2a51a Author: Hanno Becker <hanno.becker@arm.com> Date: Thu Mar 15 10:14:19 2018 +0000 Increase UDP record packing time in ssl-opt.sh The UDP tests involving the merging of multiple records into single datagrams accumulate records for 10ms, which can be less than the total flight preparation time if e.g. the tests are being run with valgrind. This commit increases the packing time for the relevant tests from 10ms to 50ms. commit 7b6582b63196bd18f5dccdcaebd9a6bd97858aa3 Author: Hanno Becker <hanno.becker@arm.com> Date: Thu Mar 15 09:37:27 2018 +0000 Kill server and proxy via SIGQUIT in ssl-opt.sh SIGKILL interferes with memory checking in valgrind. commit 79a5e72719cb23daee6e0e55f7b85659bb3a89b8 Merge: 24b2d6f 47a98d4 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 14 18:29:50 2018 +0000 Merge remote-tracking branch 'upstream-restricted/pr/463' into development-restricted-proposed commit 24b2d6fb6daccddddd0293eb345da2d8c128fa60 Merge: 8e4ff12 22797fc Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 14 18:13:47 2018 +0000 Merge remote-tracking branch 'upstream-restricted/pr/459' into development-restricted-proposed commit 8e4ff1290967f570a1331b2780cd942d0e63999b Merge: 5f19328 ce183d9 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 14 18:02:57 2018 +0000 Merge branch 'development-proposed' into development-restricted-proposed commit ce183d994c3a209ed685124833b1ace18f592b44 Merge: d1fedc5 8db3efb Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 14 17:59:07 2018 +0000 Merge remote-tracking branch 'upstream-public/pr/1448' into development-proposed commit d1fedc55d7b319a9829fa368e46afe15ae0648b2 Merge: 95ad522 7fa1ae7 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 14 17:51:58 2018 +0000 Merge remote-tracking branch 'upstream-public/pr/1440' into development-proposed commit 95ad522eccd90a3199614b1645a658618c6f494f Merge: 6429377 00bbf57 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 14 17:34:02 2018 +0000 Merge remote-tracking branch 'upstream-public/pr/1439' into development-proposed commit 64293777ebd614758e8765ab74b0322b94010e3b Merge: a53d9ab e494e20 Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 14 17:24:44 2018 +0000 Merge remote-tracking branch 'upstream-public/pr/1423' into development-proposed commit a53d9abfe8cfdd270f24f6cd6afe1032838a46ee Merge: 5f19328 b2231fc Author: Jaeden Amero <jaeden.amero@arm.com> Date: Wed Mar 14 17:22:25 2018 +0000 Merge remote-tracking branch 'upstream-public/pr/1051' into development-proposed commit 47a98d4e2c198e68538192ab72cbd0a2850dbb54 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Mar 14 14:08:57 2018 +0100 fixup previous commit: add forgotten file commit a63305d134a2223477b4bfc46774518467b687d8 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Mar 14 12:23:56 2018 +0100 x509: CRL: add tests for non-critical extension The 'critical' boolean can be set to false in two ways: - by leaving it implicit (test data generated by openssl) - by explicitly setting it to false (generated by hand) commit 0bdb050b2deffce65f728a7622a388c00a474e82 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Wed Mar 14 11:34:29 2018 +0100 x509: CRL: add tests for malformed extensions This covers all lines added in the previous commit. Coverage was tested using: make CFLAGS='--coverage -g3 -O0' (cd tests && ./test_suite_x509parse) make lcov firefox Coverage/index.html # then visual check Test data was generated by taking a copy of tests/data_files/crl-idp.pem, encoding it as hex, and then manually changing the values of some bytes to achieve the desired errors, using https://lapo.it/asn1js/ for help in locating the desired bytes. commit 7fa1ae70c85e847fcd5e434b1417c8dc4cc62c72 Author: Krzysztof Stachowiak <krzysiek.stachowiak@gmail.com> Date: Tue Mar 13 17:17:38 2018 +0100 Add Changelog entry commit 00bbf572afc5558026a65ccb1000023bd1ce872d Author: Krzysztof Stachowiak <krzysiek.stachowiak@gmail.com> Date: Wed Mar 14 11:14:13 2018 +0100 Update change log commit fd3e4fbae75049810379e0845580402502629d68 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Tue Mar 13 11:53:30 2018 +0100 x509: CRL: reject unsupported critical extensions commit 5f1932817cecd906b00512ffdec33d042433cae9 Merge: 553a06f 1ed45ea Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Tue Mar 13 17:18:06 2018 +0100 Merge remote-tracking branch 'upstream-restricted/pr/398' into development-restricted-proposed commit 553a06f08a4ece8c4276336e999e7e4a6ac5f464 Merge: f3ada4a 6f486a6 Author: Gilles Peskine <Gilles.Peskine@arm.com> Date: Tue Mar 13 17:15:34 2018 +0100 Merge remote-tracking branch 'upstream-restricted/pr/351' into development-restricted-proposed Move the added ChangeLog entry to the bottom so that the list remains in merge order. commit b6f880b63bc6afd192bd280fc178484b77cf710b Author: Hanno Becker <hanno.becker@arm.com> Date: Tue Mar 13 12:48:37 2018 +0000 Revert whitespace change to ease merging commit 1ba8a3fc55575cae21c39971c325e7f124e7f234 Author: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> Date: Tue Mar 13 13:27:14 2018 +0100 Yet another dependency issue (PKCS1_V15) Found by running: CC=clang cmake -D CMAKE_BUILD_TYPE="Check" tests/scripts/depend-pkalgs.pl (Also tested with same command but CC=gcc) Another PR will address improving all.sh and/or the depend-xxx.pl scripts themselves to catch this kind of thing. commit ccbd8a4bbbb8b44c4eb241e8…
…e-free prevent potential double free
In most cases we can avoid (or minimize impact of) clearing entire number in
mbedtls_mpi_copy
.Test shows that in about 60% of cases clearing is not needed at all (the whole number is overwritten), and in other cases less than a half of a number should be cleared. We can save some resources by clearing only required part of a number.