commit | 87d0c174c7fdc4c48b74b60e8f2f44852f41c6bf | [log] [tgz] |
---|---|---|
author | David Benjamin <davidben@google.com> | Fri Sep 20 16:45:42 2024 -0400 |
committer | Boringssl LUCI CQ <boringssl-scoped@luci-project-accounts.iam.gserviceaccount.com> | Tue Oct 08 22:10:13 2024 +0000 |
tree | 1e8954190236b6ce9bd6174fb414632e520a5340 | |
parent | 0dc8b016ee4b11ee44e284251d9e107d9df31d3d [diff] |
Add a bssl::InplaceVector to libssl We're constantly hand-rolling these inlined bounded array structures. Inspired by C++26's std::inplace_vector name, add something very basic. This is still very barebones and probably can be improved. But it's enough to be able to use spans more often. Perhaps in a decade we'll be able to just use the real one. To keep our size optimization, InplaceVector picks the minimal integer needed to represent the size but, unlike doing it by hand, this is entirely hidden from the API. I switched a pile of fields over to this to confirm it mostly works, though there are still a ton more that are array/length pairs. In particular, we never came up with a good calling convention for all the intermediate hash-sized values in the TLS 1.3 key schedule. I've left that alone for now. The immediate motivation here is that a lot of the transport-specific epoch structs will need to store the original traffic secret, and holding on to it everywhere without an abstraction is tedious. Bug: 371998381 Change-Id: I17a987299dc9278b59d2b773e1f3fead69dff162 Reviewed-on: https://boringssl-review.googlesource.com/c/boringssl/+/71748 Commit-Queue: David Benjamin <davidben@google.com> Reviewed-by: Adam Langley <agl@google.com> Reviewed-by: Bob Beck <bbe@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:
To file a security issue, use the Chromium process and mention in the report this is for BoringSSL. You can ignore the parts of the process that are specific to Chromium/Chrome.
There are other files in this directory which might be helpful: