Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/boringssl.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/crypto/ec
AgeCommit message (Collapse)Author
2015-12-17Slightly tweak some array allocations.David Benjamin
clang scan-build is annoyed it's not obvious the sizeof line matches the pointer type. This is easy to fix and makes it be quiet. Change-Id: Iec80d2a087f81179c88cae300f56d3f76b32b347 Reviewed-on: https://boringssl-review.googlesource.com/6701 Reviewed-by: Adam Langley <agl@google.com>
2015-12-16Remove the CRYPTO_EX_new callback.David Benjamin
This callback is never used. The one caller I've ever seen is in Android code which isn't built with BoringSSL and it was a no-op. It also doesn't actually make much sense. A callback cannot reasonably assume that it sees every, say, SSL_CTX created because the index may be registered after the first SSL_CTX is created. Nor is there any point in an EX_DATA consumer in one file knowing about an SSL_CTX created in completely unrelated code. Replace all the pointers with a typedef to int*. This will ensure code which passes NULL or 0 continues to compile while breaking code which passes an actual function. This simplifies some object creation functions which now needn't worry about CRYPTO_new_ex_data failing. (Also avoids bouncing on the lock, but it's taking a read lock, so this doesn't really matter.) BUG=391192 Change-Id: I02893883c6fa8693682075b7b130aa538a0a1437 Reviewed-on: https://boringssl-review.googlesource.com/6625 Reviewed-by: Adam Langley <agl@google.com>
2015-12-15Enforce that |EC_KEY| private key is in [0, group->order).Brian Smith
Change-Id: I16abea5769737c7edd1be717f9a4f38678af43ce Reviewed-on: https://boringssl-review.googlesource.com/6564 Reviewed-by: Adam Langley <agl@google.com>
2015-12-15Add |EC_METHOD| method for verifying public key order.Brian Smith
In some cases it would be good to restrict the input range of scalars given to |EC_METHOD::mul| to be [0, order-1]. This is a first step towards that goal. Change-Id: I58a25db06f6c7a68a0ac1fe79794b04f7a173b23 Reviewed-on: https://boringssl-review.googlesource.com/6562 Reviewed-by: Adam Langley <agl@google.com>
2015-12-15Add |EC_GROUP_get0_order| to replace |EC_GROUP_get_order|.Brian Smith
|EC_GROUP_get0_order| doesn't require any heap allocations and never fails, so it is much more convenient and more efficient for callers to call. Change-Id: Ic60f768875e7bc8e74362dacdb5cbbc6957b05a6 Reviewed-on: https://boringssl-review.googlesource.com/6532 Reviewed-by: Adam Langley <agl@google.com>
2015-11-21Remove dead code in p256-x86_64.Brian Smith
Change-Id: I9d0b3fa39445d08202c67d905d2c676d5d968c33 Reviewed-on: https://boringssl-review.googlesource.com/6561 Reviewed-by: Adam Langley <agl@google.com>
2015-11-19Share common definitions of |TOBN| and |BIGNUM_STATIC|.Brian Smith
Previously, both crypto/dh and crypto/ec defined |TOBN| macros that did the same thing, but which took their arguments in the opposite order. This change makes the code consistently use the same macro. It also makes |STATIC_BIGNUM| available for internal use outside of crypto/bn. Change-Id: Ide57f6a5b74ea95b3585724c7e1a630c82a864d9 Reviewed-on: https://boringssl-review.googlesource.com/6528 Reviewed-by: Adam Langley <agl@google.com>
2015-11-19Remove |EC_POINTs_mul| & simplify p256-x86_64.Brian Smith
Without |EC_POINTs_mul|, there's never more than one variable point passed to a |EC_METHOD|'s |mul| method. This allows them to be simplified considerably. In this commit, the p256-x86_64 implementation has been simplified to eliminate the heap allocation and looping related that was previously necessary to deal with the possibility of there being multiple input points. The other implementations were left mostly as-is; they should be similarly simplified in the future. Change-Id: I70751d1d5296be2562af0730e7ccefdba7a1acae Reviewed-on: https://boringssl-review.googlesource.com/6493 Reviewed-by: Adam Langley <agl@google.com>
2015-11-19Fix error handling in |p256-x86_64|.Brian Smith
This makes similar fixes as were done in the following OpenSSL commits: c028254b12a8ea0d0f8a677172eda2e2d78073f3: Correctly set Z_is_one on the return value in the NISTZ256 implementation. e22d2199e2a5cc9b243f45c2b633d1e31fadecd7: Error checking and memory leak leak fixes in NISTZ256. 4446044a793a9103a4bc70c0214005e6a4463767: NISTZ256: set Z_is_one to boolean 0/1 as is customary. a4d5269e6d0dba0c276c968448a3576f7604666a: NISTZ256: don't swallow malloc errors. The fixes aren't exactly the same. In particular, the comments "This is an unusual input, we don't guarantee constant-timeness" and the changes to |ecp_nistz256_mult_precompute| (which isn't in BoringSSL) were omitted. Change-Id: Ia7bb982daa62fb328e8bd2d4dd49a8857e104096 Reviewed-on: https://boringssl-review.googlesource.com/6492 Reviewed-by: Adam Langley <agl@google.com>
2015-11-19Remove |EC_GROUP_precompute_mult| and |EC_KEY_precompute_mult|.Brian Smith
Change-Id: I1663ec6046b8f1f67a62e4c6483af719d6f362ad Reviewed-on: https://boringssl-review.googlesource.com/6486 Reviewed-by: Adam Langley <agl@google.com>
2015-11-19Make |EC_GROUP_precompute_mult|/|EC_KEY_precompute_mult| no-ops.Brian Smith
This moves us closer to having |EC_GROUP| and |EC_KEY| being immutable. The functions are left as no-ops for backward compatibility. Change-Id: Ie23921ab0364f0771c03aede37b064804c9f69e0 Reviewed-on: https://boringssl-review.googlesource.com/6485 Reviewed-by: Adam Langley <agl@google.com>
2015-11-19Remove p224-64 and p256-64 dead code for non-default generators.Brian Smith
This extends 9f1f04f31359330702451bc74ab98dca3abca602 to the other implementations. |EC_GFp_nistp224_method| and |EC_GFp_nistp256_method| are not marked |OPENSSL_EXPORT|. |EC_GROUP_set_generator| doesn't allow the generator to be changed for any |EC_GROUP| for built-in curves. Consequently, there's no way (except some kind of terrible abuse) that this code could be executed with a non-default generator. Change-Id: I5d9b6be4e6f9d384159cb3d708390a8e3c69f23f Reviewed-on: https://boringssl-review.googlesource.com/6489 Reviewed-by: Adam Langley <agl@google.com>
2015-11-13Don't encode or decode ∞.Adam Langley
|EC_POINT_point2oct| would encode ∞, which is surprising, and |EC_POINT_oct2point| would decode ∞, which is insane. This change removes both behaviours. Thanks to Brian Smith for pointing it out. Change-Id: Ia89f257dc429a69b9ea7b7b15f75454ccc9c3bdd Reviewed-on: https://boringssl-review.googlesource.com/6488 Reviewed-by: Adam Langley <agl@google.com>
2015-11-13Remove point-on-curve check from |ec_GFp_simple_oct2point|.Adam Langley
In the case of a compressed point, the decompression ensures that the point is on the curve. In the uncompressed case, |EC_POINT_set_affine_coordinates_GFp| checks that the point is on the curve as of 38feb990a183362397ebc62774cc07374d146c83. Change-Id: Icd69809ae396838b4aef4fa89b3b354560afed55 Reviewed-on: https://boringssl-review.googlesource.com/6487 Reviewed-by: Brian Smith <brian@briansmith.org> Reviewed-by: Adam Langley <agl@google.com>
2015-11-12Remove `EC_GFp_simple_method` (dead code).Brian Smith
Change-Id: I1820bd5412313e00a69123370178c0fe3e12b5ef Reviewed-on: https://boringssl-review.googlesource.com/6482 Reviewed-by: Adam Langley <agl@google.com>
2015-11-12Fix null pointer dereference when using "simple" EC.Brian Smith
This regressed in f0523e9f2046a249210c6dd86fdcbe069ea9912d. Change-Id: I70c3fcb0d91ac00e5088b086312384756eda6140 Reviewed-on: https://boringssl-review.googlesource.com/6481 Reviewed-by: Adam Langley <agl@google.com>
2015-11-12Remove nistz256 dead code for non-default generators.Brian Smith
|EC_GFp_nistz256_method| is not marked |OPENSSL_EXPORT| so only the built-in P-256 curve uses it. |EC_GROUP_set_generator| doesn't allow the generator to be changed for any |EC_GROUP| for a built-in curve. Consequently, there's no way (except some kind of terrible abuse) that the nistz code could be executed with a non-default generator. Change-Id: Ib22f00bc74c103b7869ed1e35032b1f3d26cdad2 Reviewed-on: https://boringssl-review.googlesource.com/6446 Reviewed-by: Adam Langley <agl@google.com>
2015-11-12Remove stl_compat.h.David Benjamin
Chromium's toolchains may now assume C++11 library support, so we may freely use C++11 features. (Chromium's still in the process of deciding what to allow, but we use Google's style guide directly, toolchain limitations aside.) Change-Id: I1c7feb92b7f5f51d9091a4c686649fb574ac138d Reviewed-on: https://boringssl-review.googlesource.com/6465 Reviewed-by: Adam Langley <agl@google.com>
2015-11-06Require that EC points are on the curve.Adam Langley
This removes a sharp corner in the API where |ECDH_compute_key| assumed that callers were either using ephemeral keys, or else had already checked that the public key was on the curve. A public key that's not on the curve can be in a small subgroup and thus the result can leak information about the private key. This change causes |EC_POINT_set_affine_coordinates_GFp| to require that points are on the curve. |EC_POINT_oct2point| already does this. Change-Id: I77d10ce117b6efd87ebb4a631be3a9630f5e6636 Reviewed-on: https://boringssl-review.googlesource.com/5861 Reviewed-by: Adam Langley <agl@google.com>
2015-11-04Fix several MSVC warnings.Adam Langley
MSVC reports lots of: warning C4090: 'function' : different 'const' qualifiers Change-Id: If8184538c44e657f6234252d0147396d1a18b36c
2015-11-04(Hopefully) fix a warning on Windows.Adam Langley
MSVC unhelpfuly says: warning C4146: unary minus operator applied to unsigned type, result still unsigned. Change-Id: Ia1e6b9fc415908920abb1bcd98fc7f7a5670c2c7
2015-11-04Initialise variable before jump.Adam Langley
Clang finds: crypto/ec/ec.c:420:7: error: variable 'ok' is used uninitialized whenever 'if' condition is true [-Werror,-Wsometimes-uninitialized] if (ctx == NULL) { ^~~~~~~~~~~ Change-Id: I33fc4d74ff3a3bd52ab155f8273fbcd9c6256e35
2015-11-04Add Intel's P-256Adam Langley
This change incorporates Intel's P-256 implementation. The record of Intel's submission under CLA is in internal bug number 25330687. Before: Did 3582 ECDH P-256 operations in 1049114us (3414.3 ops/sec) Did 8525 ECDSA P-256 signing operations in 1028778us (8286.5 ops/sec) Did 3487 ECDSA P-256 verify operations in 1008996us (3455.9 ops/sec) build/tool/bssl is 1434704 bytes after strip -s After: Did 8618 ECDH P-256 operations in 1027884us (8384.2 ops/sec) Did 21000 ECDSA P-256 signing operations in 1049490us (20009.7 ops/sec) Did 8268 ECDSA P-256 verify operations in 1079481us (7659.2 ops/sec) build/tool/bssl is 1567216 bytes after strip -s Change-Id: I147971a8e19849779c8ed7e20310d41bd4962299 Reviewed-on: https://boringssl-review.googlesource.com/6371 Reviewed-by: Adam Langley <agl@google.com>
2015-10-28Fix all sign/unsigned warnings with Clang and GCC.Adam Langley
Change-Id: If2a83698236f7b0dcd46701ccd257a85463d6ce5 Reviewed-on: https://boringssl-review.googlesource.com/4992 Reviewed-by: Adam Langley <agl@google.com>
2015-10-27Change the type of |EC_GROUP_get_degree| and friends to |unsigned|.Brian Smith
These functions ultimately return the result of |BN_num_bits|, and that function's return type is |unsigned|. Thus, these functions' return type should also be |unsigned|. Change-Id: I2cef63e6f75425857bac71f7c5517ef22ab2296b Reviewed-on: https://boringssl-review.googlesource.com/6170 Reviewed-by: Adam Langley <alangley@gmail.com>
2015-10-27Add OPENSSL_SMALL.Adam Langley
Intel's P-256 code has very large tables and things like Chromium just don't need that extra size. However, servers generally do so this change adds an OPENSSL_SMALL define that currently just drops the 64-bit P-224 but will gate Intel's P-256 in the future too. Change-Id: I2e55c6e06327fafabef9b96d875069d95c0eea81 Reviewed-on: https://boringssl-review.googlesource.com/6362 Reviewed-by: Adam Langley <alangley@gmail.com>
2015-10-27Avoid hard-coded linkage of WNAF-based multiplication.Brian Smith
If the application is only using the P-256 implementation in p256-64.c, then the WNAF code would all be dead code. The change reorganizes the code so that all modern toolchains should be able to recognize that fact and eliminate the WNAF-based code when it is unused. Change-Id: I9f94bd934ca7d2292de4c29bb89e17c940c7cd2a Reviewed-on: https://boringssl-review.googlesource.com/6173 Reviewed-by: Adam Langley <alangley@gmail.com>
2015-10-27Simplify |EC_METHOD| by removing invariant methods.Brian Smith
None of these methods vary per group. Factoring these out of |EC_METHOD| should help some toolchains to do a better job optimizing the code for size. Change-Id: Ibd22a52992b4d549f12a8d22bddfdb3051aaa891 Reviewed-on: https://boringssl-review.googlesource.com/6172 Reviewed-by: Adam Langley <alangley@gmail.com>
2015-10-26Add a run_tests target to run all tests.David Benjamin
It's very annoying having to remember the right incant every time I want to switch around between my build, build-release, build-asan, etc., output directories. Unfortunately, this target is pretty unfriendly without CMake 3.2+ (and Ninja 1.5+). This combination gives a USES_TERMINAL flag to add_custom_target which uses Ninja's "console" pool, otherwise the output buffering gets in the way. Ubuntu LTS is still on an older CMake, so do a version check in the meantime. CMake also has its own test mechanism (CTest), but this doesn't use it. It seems to prefer knowing what all the tests are and then tries to do its own output management and parallelizing and such. We already have our own runners. all_tests.go could actually be converted tidily, but generate_build_files.py also needs to read it, and runner.go has very specific needs. Naming the target ninja -C build test would be nice, but CTest squats that name and CMake grumps when you use a reserved name, so I've gone with run_tests. Change-Id: Ibd20ebd50febe1b4e91bb19921f3bbbd9fbcf66c Reviewed-on: https://boringssl-review.googlesource.com/6270 Reviewed-by: Adam Langley <alangley@gmail.com>
2015-10-08Add optimised version of P-224.Adam Langley
This imports the Google-authored P-224 implementation by Emilia Käsper and Bodo Möller that is also in upstream OpenSSL. Change-Id: I16005c74a2a3e374fb136d36f3f6569dab9d8919 Reviewed-on: https://boringssl-review.googlesource.com/6145 Reviewed-by: Adam Langley <agl@google.com>
2015-09-29d2i: don't update input pointer on failureDavid Benjamin
(Imported from upstream's 728bcd59d3d41e152aead0d15acc51a8958536d3.) Actually this one was reported by us, but the commit message doesn't mention this. This is slightly modified from upstream's version to fix some problems noticed in import. Specifically one of d2i_X509_AUX's success paths is bust and d2i_PrivateKey still updates on one error path. Resolve the latter by changing both it and d2i_AutoPrivateKey to explicitly hit the error path on ret == NULL. This lets us remove the NULL check in d2i_AutoPrivateKey. We'll want to report the problems back upstream. Change-Id: Ifcfc965ca6d5ec0a08ac154854bd351cafbaba25 Reviewed-on: https://boringssl-review.googlesource.com/5948 Reviewed-by: Adam Langley <agl@google.com>
2015-08-26Move arm_arch.h and fix up lots of include paths.Adam Langley
arm_arch.h is included from ARM asm files, but lives in crypto/, not openssl/include/. Since the asm files are often built from a different location than their position in the source tree, relative include paths are unlikely to work so, rather than having crypto/ be a de-facto, second global include path, this change moves arm_arch.h to include/openssl/. It also removes entries from many include paths because they should be needed as relative includes are always based on the locations of the source file. Change-Id: I638ff43d641ca043a4fc06c0d901b11c6ff73542 Reviewed-on: https://boringssl-review.googlesource.com/5746 Reviewed-by: Adam Langley <agl@google.com>
2015-08-21Don't use the uint128_t P-256 code under MSAN.Adam Langley
MSAN appears to have a bug that causes this code to be miscompiled when compiled with optimisations. In order to prevent that bug from holding everything up, this change disables that code when MEMORY_SANITIZER is defined. The generic elliptic-curve code can pick up the slack in that case. Change-Id: I7ce26969b3ee0bc0b0496506f06a8cf9b2523cfa
2015-08-07Clean up weirdness in initializing EC_GROUP cofactor & order.Brian Smith
Previously, |x| was reset to the value of the cofactor for no reason, and there was an unnecessary copy made of |order|. Change-Id: Ib6b06f651e280838299dff534c38726ebf4ccc97 Reviewed-on: https://boringssl-review.googlesource.com/4447 Reviewed-by: Adam Langley <agl@google.com>
2015-08-07Free tmp_wNAF in all exit paths.David Benjamin
BUG=517495 Change-Id: I67c9c511d4ed558ab7a976d6708398e02194cd0f Reviewed-on: https://boringssl-review.googlesource.com/5628 Reviewed-by: Adam Langley <agl@google.com>
2015-08-07Improve error checking of some |BN_CTX_get| callers.Brian Smith
The documentation for |BN_CTX_get| states: "Once |BN_CTX_get| has returned NULL, all future calls will also return NULL until |BN_CTX_end| is called." Some code takes advantage of that guarantee by only checking the return value of the last call to |BN_CTX_get| in a series of calls. That is correct and the most efficient way of doing it. However, that pattern is inconsistent with most of the other uses of |BN_CTX_get|. Also, static analysis tools like Coverity cannot understand that pattern. This commit removes the instances of that pattern that Coverity complained about when scanning *ring*. Change-Id: Ie36d0223ea1caee460c7979547cf5bfd5fb16f93 Reviewed-on: https://boringssl-review.googlesource.com/5611 Reviewed-by: Adam Langley <agl@google.com>
2015-07-16Remove the func parameter to OPENSSL_PUT_ERROR.David Benjamin
Much of this was done automatically with find . -name '*.c' | xargs sed -E -i '' -e 's/(OPENSSL_PUT_ERROR\([a-zA-Z_0-9]+, )[a-zA-Z_0-9]+, ([a-zA-Z_0-9]+\);)/\1\2/' find . -name '*.c' | xargs sed -E -i '' -e 's/(OPENSSL_PUT_ERROR\([a-zA-Z_0-9]+, )[a-zA-Z_0-9]+, ([a-zA-Z_0-9]+\);)/\1\2/' BUG=468039 Change-Id: I4c75fd95dff85ab1d4a546b05e6aed1aeeb499d8 Reviewed-on: https://boringssl-review.googlesource.com/5276 Reviewed-by: Adam Langley <agl@google.com>
2015-05-21Fix some malloc test crashs.David Benjamin
This isn't exhaustive. There are still failures in some tests which probably ought to get C++'d first. Change-Id: Iac58df9d98cdfd94603d54374a531b2559df64c3 Reviewed-on: https://boringssl-review.googlesource.com/4795 Reviewed-by: Adam Langley <agl@google.com>
2015-05-21Add malloc test support to unit tests.David Benjamin
Currently far from passing and I haven't even tried with a leak checker yet. Also bn_test is slow. Change-Id: I4fe2783aa5f7897839ca846062ae7e4a367d2469 Reviewed-on: https://boringssl-review.googlesource.com/4794 Reviewed-by: Adam Langley <agl@google.com>
2015-05-20Convert reference counts in crypto/Adam Langley
This change converts the reference counts in crypto/ to use |CRYPTO_refcount_t|. The reference counts in |X509_PKEY| and |X509_INFO| were never actually used and so were dropped. Change-Id: I75d572cdac1f8c1083c482e29c9519282d7fd16c Reviewed-on: https://boringssl-review.googlesource.com/4772 Reviewed-by: Adam Langley <agl@google.com>
2015-05-15Support arbitrary elliptic curve groups.Adam Langley
This change exposes the functions needed to support arbitrary elliptic curve groups. The Java API[1] doesn't allow a provider to only provide certain elliptic curve groups. So if BoringSSL is an ECC provider on Android, we probably need to support arbitrary groups because someone out there is going to be using it for Bitcoin I'm sure. Perhaps in time we can remove this support, but not yet. [1] https://docs.oracle.com/javase/7/docs/api/java/security/spec/ECParameterSpec.html Change-Id: Ic1d76de96f913c9ca33c46b451cddc08c5b93d80 Reviewed-on: https://boringssl-review.googlesource.com/4740 Reviewed-by: David Benjamin <davidben@chromium.org> Reviewed-by: Adam Langley <agl@google.com>
2015-05-14Copy ecdsa_meth in EC_KEY_copy.Shawn Willden
Change-Id: Ia97e76d6e5a5dc216a05741864c3d59b50d855bd Reviewed-on: https://boringssl-review.googlesource.com/4750 Reviewed-by: Adam Langley <agl@google.com>
2015-05-09Don't report |ERR_R_MALLOC_FAILURE| on failure of |EC_KEY_new_by_curve_name|.Matt Braithwaite
Change |EC_KEY_new_by_curve_name| to report |ERR_R_MALLOC_FAILURE| itself, so that reporting of |EC_R_UNKNOWN_GROUP| is not confused by the caller's addition of a spurious |ERR_R_MALLOC_FAILURE|. Change-Id: Id3f5364f01eb8e3597bcddd6484bc03d5578befb Reviewed-on: https://boringssl-review.googlesource.com/4690 Reviewed-by: Adam Langley <agl@google.com>
2015-05-05Add dummy EC_GROUP_set_point_conversion_form.Adam Langley
BoringSSL always uses uncompressed points. This function aborts if another form is requested or does nothing if uncompressed points are requested. Change-Id: I80bc01444cdf9c789c9c75312b5527bf4957361b
2015-05-05Remove unnecessary NULL checks, part 2.David Benjamin
Stuff in crypto/ec. Change-Id: I3bd238c365c4766ed8abc6f835a107478b43b159 Reviewed-on: https://boringssl-review.googlesource.com/4515 Reviewed-by: Adam Langley <agl@google.com>
2015-05-05Make a few variable names saner.David Benjamin
Change-Id: I6790dc9651dc400992fc59a4c900210edeb2520c Reviewed-on: https://boringssl-review.googlesource.com/4511 Reviewed-by: Adam Langley <agl@google.com>
2015-04-29Don't inclue crypto/ec/internal.h in ec_test.cc.David Benjamin
MSVC seems to dislike the zero-array trick in C++, but not C. Turns out there was no need for the include, so that's an easy fix. Change-Id: I6def7b430a450c4ff7eeafa3611f0d40f5fc5945 Reviewed-on: https://boringssl-review.googlesource.com/4580 Reviewed-by: Adam Langley <agl@google.com>
2015-04-29Ensure EC private keys retain leading zerosDavid Benjamin
RFC 5915 requires the use of the I2OSP primitive as defined in RFC 3447 for encoding ECPrivateKey. Fix this and add a test. See also upstream's 30cd4ff294252c4b6a4b69cbef6a5b4117705d22, though it mixes up degree and order. Change-Id: I81ba14da3c8d69e3799422c669fab7f16956f322 Reviewed-on: https://boringssl-review.googlesource.com/4469 Reviewed-by: Adam Langley <agl@google.com>
2015-04-29Convert ec_test to C++David Benjamin
Change-Id: I5e25ddbc87370b58d9b6fc410f51e259947df8dd Reviewed-on: https://boringssl-review.googlesource.com/4468 Reviewed-by: Adam Langley <agl@google.com>
2015-04-20Fix standalone build on Mac.David Benjamin
CRYPTO_MUTEX was the wrong size. Fortunately, Apple was kind enough to define pthread_rwlock_t unconditionally, so we can be spared fighting with feature macros. Some of the stdlib.h removals were wrong and clang is pick about multiply-defined typedefs. Apparently that's a C11 thing? BUG=478598 Change-Id: Ibdcb8de9e5d83ca28e4c55b2979177d1ef0f9721 Reviewed-on: https://boringssl-review.googlesource.com/4404 Reviewed-by: Adam Langley <agl@google.com>