- Nov 05, 2018
-
-
Bernd Edlinger authored
Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7519)
-
Bernd Edlinger authored
Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7519)
-
Pauli authored
Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> (Merged from https://github.com/openssl/openssl/pull/7564) (cherry picked from commit 2087028612027368e9508e1b253aab715a5a35d6)
-
Pauli authored
Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> (Merged from https://github.com/openssl/openssl/pull/7564) (cherry picked from commit e931f370aa38d8645b35fb8d6260cb44d37b6b61)
-
- Nov 04, 2018
-
-
Benjamin Kaduk authored
Commit 9ef9088c switched the SSL/SSL_CTX statistics counters to using Thread-Sanitizer-friendly primitives. However, it erroneously converted an addition of -1 (for s->session_ctx->stats.sess_accept) to an addition of +1, since that is the only counter API provided by the internal tsan_assist.h header until the previous commit. This means that for each accepted (initial) connection, the session_ctx's counter would get doubly incremented, and the (switched) ctx's counter would also get incremented. Restore the counter decrement so that each accepted connection increments exactly one counter exactly once (in net effect). Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7464) (cherry picked from commit 2aaa0b14)
-
Benjamin Kaduk authored
The existing tsan_counter() API increments a reference counter. Provide a new API, tsan_decr(), to decrement such a reference counter. This can be used, for example, when a reference is added to the session_ctx's sess_accept stats but should more properly be tracked in the regular ctx's statistics. Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7464) (cherry picked from commit 95658c32436017aeeef3d8598957071baf6769a9)
-
- Nov 02, 2018
-
-
Richard Levitte authored
If engine building fails for some reason, we must make sure to close the /dev/crypto handle. Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de> (Merged from https://github.com/openssl/openssl/pull/7506) (cherry picked from commit 681e8cac)
-
Richard Levitte authored
We opened /dev/crypto once for each session, which is quite unnecessary. With this change, we open /dev/crypto once at engine init, and close it on unload. Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de> (Merged from https://github.com/openssl/openssl/pull/7506) (cherry picked from commit 458c7dad)
-
Richard Levitte authored
Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de> (Merged from https://github.com/openssl/openssl/pull/7506) (cherry picked from commit 28ac1bd9)
-
Richard Levitte authored
Copying an EVP_MD_CTX, including the implementation local bits, is a necessary operation. In this case, though, it's the same as initializing the local bits to be "copied to". Fixes #7495 Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de> (Merged from https://github.com/openssl/openssl/pull/7506) (cherry picked from commit 36af124b)
-
Richard Levitte authored
The documentation says some commands care, but the code says differently. Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7440) (cherry picked from commit d91d443f)
-
- Nov 01, 2018
-
-
Pauli authored
Reviewed-by: Tim Hudson <tjh@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7549) (cherry picked from commit 00496b6423605391864fbbd1693f23631a1c5239)
-
- Oct 31, 2018
-
-
Richard Levitte authored
This makes sure that any resulting directory target in the build files also depend on object files meant for shared libraries. As a side effect, we move the production of the dirinfo structure from common.tmpl to Configure, to make it easier to check the result. Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7452) (cherry picked from commit b6e660754c2e799cffe4906269fcace0e07c73bc)
-
Andy Polyakov authored
This excluses user from additional PATH adjustments in case NDK has llvm-ar. Reviewed-by: Matt Caswell <matt@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7443) (cherry picked from commit ddf2e8c8ccad49cff0d6a0a0b26ca892ec4ce33a)
-
Andy Polyakov authored
03ad7c009e16a233c733098db3169c560142ccd3 failed if one didn't pass explicit -D__ANDROID_API__=N :-( Reviewed-by: Matt Caswell <matt@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7443) (cherry picked from commit 71f2b3171e8b94b0fbdc7fab2d7ca4ea66edec2b)
-
- Oct 30, 2018
-
-
Bernd Edlinger authored
Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7523) (cherry picked from commit 4011bab1f85d4429bad1e9388bed90a8d0da5639)
-
Matt Caswell authored
Reviewed-by: Ben Kaduk <kaduk@mit.edu> (Merged from https://github.com/openssl/openssl/pull/7413) (cherry picked from commit 6e46c065b9b97212d63ef1f321b08fb7fa6b320d)
-
Matt Caswell authored
In TLSv1.2 and below a CertificateRequest is sent after the Certificate from the server. This means that by the time the client_cert_cb is called on receipt of the CertificateRequest a call to SSL_get_peer_certificate() will return the server certificate as expected. In TLSv1.3 a CertificateRequest is sent before a Certificate message so calling SSL_get_peer_certificate() returns NULL. To workaround this we delay calling the client_cert_cb until after we have processed the CertificateVerify message, when we are doing TLSv1.3. Fixes #7384 Reviewed-by: Ben Kaduk <kaduk@mit.edu> (Merged from https://github.com/openssl/openssl/pull/7413) (cherry picked from commit e4562014)
-
Dr. Matthias St. Pierre authored
The RAND_DRBG_TYPE preprocessor define depends on a NID, so we have to include obj_mac.h to make the header selfcontained. Fixes #7521 Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7524) (cherry picked from commit cf3d6ef7af7d6c47f5ccd4ce58d822972018b21c)
-
Chocobo1 authored
CLA: trivial Reviewed-by: Tim Hudson <tjh@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7444) (cherry picked from commit cf4eea12046445fc418507d2d5e14956b4353495)
-
- Oct 29, 2018
-
-
Richard Levitte authored
pkey_test_ctrl() was designed for parsing values, not for using in test runs. Relying on its returned value when it returned 1 even for control errors made it particularly useless for mac_test_run(). Here, it gets replaced with a MAC specific control function, that parses values the same way but is designed for use in a _run() rather than a _parse() function. This uncovers a SipHash test with an invalid control that wasn't caught properly. After all, that stanza is supposed to test that invalid control values do generate an error. Now we catch that. Reviewed-by: Tim Hudson <tjh@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7500) (cherry picked from commit ce5d64c79c4d809ece8fe28a5b62915467a1c0e1)
-
Matt Caswell authored
Reviewed-by: Tim Hudson <tjh@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7501) (cherry picked from commit 10d5b415)
-
Matt Caswell authored
Fixes #7497 Reviewed-by: Tim Hudson <tjh@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7501) (cherry picked from commit ca55d70be031746daddd8bd0611db54ed81f1737)
-
Richard Levitte authored
We made the build of foo.obj depend on foo.d, meaning the latter gets built first. Unfortunately, the way the compiler works, we are forced to redirect all output to foo.d, meaning that if the source contains an error, the build fails without showing those errors. We therefore remove the dependency and force the build of foo.d to always happen after build of foo.obj. Reviewed-by: Tim Hudson <tjh@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7469) (cherry picked from commit ecc347f5f53a9f2edc2805d50cba07db64267e8a)
-
Richard Levitte authored
Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7194) (cherry picked from commit 60690b5b8396d7d5234cd067206190fb8aca78d2)
-
Richard Levitte authored
Needed to clear a clash between ERR_load_CRYPTO_strings and ERR_load_crypto_strings Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7194) (cherry picked from commit cc3a2e4f51679d99507a979f9a920f6068473aa2)
-
Richard Levitte authored
Believe it or not, the VMS C compiler is remarking on this Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7194) (cherry picked from commit 4602cc85aff35b7aa5e27dc57ead89f0867637f9)
-
Bernd Edlinger authored
Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7504) (cherry picked from commit f9e43929c46b38667f67e02765fe0f1c0d3061d6)
-
- Oct 28, 2018
-
-
Dr. Matthias St. Pierre authored
Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7510) (cherry picked from commit 040a03470c7c5bf95fe8e6143db7bef357a22833)
-
Pauli authored
Preallocate an extra limb for some of the big numbers to avoid a reallocation that can potentially provide a side channel. Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de> (Merged from https://github.com/openssl/openssl/pull/7486) (cherry picked from commit 99540ec79491f59ed8b46b4edf130e17dc907f52)
-
Pauli authored
Avoid a timing attack that leaks information via a side channel that triggers when a BN is resized. Increasing the size of the BNs prior to doing anything with them suppresses the attack. Thanks due to Samuel Weiser for finding and locating this. Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de> (Merged from https://github.com/openssl/openssl/pull/7486) (cherry picked from commit a9cfb8c2aa7254a4aa6a1716909e3f8cb78049b6)
-
Pauli authored
There is a side channel attack against the division used to calculate one of the modulo inverses in the DSA algorithm. This change takes advantage of the primality of the modulo and Fermat's little theorem to calculate the inverse without leaking information. Thanks to Samuel Weiser for finding and reporting this. Reviewed-by: Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com> Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de> (Merged from https://github.com/openssl/openssl/pull/7487) (cherry picked from commit 415c33563528667868c3c653a612e6fc8736fd79)
-
Dr. Matthias St. Pierre authored
Found by Coverity Scan Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de> Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7511) (cherry picked from commit 59f90557dd6e35cf72ac72016609d759ac78fcb9)
-
Richard Levitte authored
This also gave enough reason to collect the stuff that's common for all iOS config targets into the template "ios-common". Fixes #7318 Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7403) (cherry picked from commit 04e3f9a114c2c142356ef1639d68397a72e0c7f8)
-
Dr. Matthias St. Pierre authored
The new Configure summary box (41349b5e6db) now hides the warning about the missing seed source (2805ee1e ) too much. To make it more visible again, add warning markers. Reviewed-by: Richard Levitte <levitte@openssl.org> (Merged from https://github.com/openssl/openssl/pull/7509) (cherry picked from commit caa8595276c60f009c8621ad466338d2ae39fb86)
-
- Oct 27, 2018
-
-
Bernd Edlinger authored
Fixes #7394 Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7399) (cherry picked from commit a83dc59afa2e0207180d7218efed19b20d48de95)
-
Dr. Matthias St. Pierre authored
Commit 5b4cb385c18a (#7382) introduced a bug which had the effect that RAND_add()/RAND_seed() failed for buffer sizes less than 32 bytes. The reason was that now the added random data was used exlusively as entropy source for reseeding. When the random input was too short or contained not enough entropy, the DRBG failed without querying the available entropy sources. This commit makes drbg_add() act smarter: it checks the entropy requirements explicitely. If the random input fails this check, it won't be added as entropy input, but only as additional data. More precisely, the behaviour depends on whether an os entropy source was configured (which is the default on most os): - If an os entropy source is avaible then we declare the buffer content as additional data by setting randomness to zero and trigger a regular reseeding. - If no os entropy source is available, a reseeding will fail inevitably. So drbg_add() uses a trick to mix the buffer contents into the DRBG state without forcing a reseeding: it generates a dummy random byte, using the buffer content as additional data. Related-to: #7449 Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7456) (cherry picked from commit 8817215d5c52a76f2b184b624bde4df8556dee6d)
-
- Oct 26, 2018
-
-
Dr. Matthias St. Pierre authored
In commit 8bf366519661 some renamings andd typo fixes were made while adding back the DRBG-HMAC and DRBG-HASH implementation. Since the commit could not be backported, a lot of unnecessary differences between master and 1.1.1 were introduced. These differences result in tiresome merge conflicts when cherry-picking. To minimize these merge-conflicts, this patch ports all 'non-feature' changes of commit 8bf366519661 (e.g., renamings of private variables, fixes of typographical errors, comment changes) manually back to 1.1.1. The commits a83dc59afa2e (#7399) and 8817215d5c52 (#7456) failed to cherry-pick previously to 1.1.1, with this patch they both cherry-pick without conflicts. Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de> (Merged from https://github.com/openssl/openssl/pull/7505)
-
Matt Caswell authored
Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7414) (cherry picked from commit f1358634)
-
Matt Caswell authored
Since 1fb9fdc3 we may attempt to buffer a record from the next epoch that has already been buffered. Prior to that this never occurred. We simply ignore a failure to buffer a duplicated record. Fixes #6902 Reviewed-by: Paul Dale <paul.dale@oracle.com> (Merged from https://github.com/openssl/openssl/pull/7414) (cherry picked from commit 840facc3ccab481e1a0bc2cb6e7740e362df7422)
-