commit | 7cac8faff275f2c47f5c8c6b226eb2f964b13a25 | [log] [tgz] |
---|---|---|
author | David Benjamin <davidben@google.com> | Wed Oct 20 17:17:57 2021 -0400 |
committer | Boringssl LUCI CQ <boringssl-scoped@luci-project-accounts.iam.gserviceaccount.com> | Mon Oct 25 19:06:48 2021 +0000 |
tree | 9fffc75d4d5fb4a91d6ae3f1d1dc4d53cf335c8e | |
parent | 28c48e38a4489e77e2b00fb8ca5d46ea0f21618f [diff] |
Add CRYPTO_BUFFER_new_from_static_data_unsafe. When making a CRYPTO_BUFFER from a static, const buffer, there is no need to make a copy of the data. Instead, we can reference it directly. The hope is this will save a bit of memory in Chromium, since root store certs will already in static data. Moreover, by letting static CRYPTO_BUFFERs participate in pooling, we can extend the memory savings to yet other copies of these certs. For instance, if we make the root store updatable via component updater, most of the updated roots will likely already be in the binary's copy. Pooling will transparently dedup those and avoid retaining an extra copy. (I haven't gone as far as to give static CRYPTO_BUFFERs strong references from the pool, since that seems odd. But something like Chromium probably wants to intentionally leak the initial static ones so that, when all references go away, they're still available for pooling.) Change-Id: I05c25c5ff618f9f7a6ed21e4575cf659e7c32811 Reviewed-on: https://boringssl-review.googlesource.com/c/boringssl/+/50045 Commit-Queue: David Benjamin <davidben@google.com> Reviewed-by: Adam Langley <agl@google.com>
BoringSSL is a fork of OpenSSL that is designed to meet Google's needs.
Although BoringSSL is an open source project, it is not intended for general use, as OpenSSL is. We don't recommend that third parties depend upon it. Doing so is likely to be frustrating because there are no guarantees of API or ABI stability.
Programs ship their own copies of BoringSSL when they use it and we update everything as needed when deciding to make API changes. This allows us to mostly avoid compromises in the name of compatibility. It works for us, but it may not work for you.
BoringSSL arose because Google used OpenSSL for many years in various ways and, over time, built up a large number of patches that were maintained while tracking upstream OpenSSL. As Google's product portfolio became more complex, more copies of OpenSSL sprung up and the effort involved in maintaining all these patches in multiple places was growing steadily.
Currently BoringSSL is the SSL library in Chrome/Chromium, Android (but it's not part of the NDK) and a number of other apps/programs.
Project links:
There are other files in this directory which might be helpful: