Skip to content

Merge in upstream v5.0.0 - #41

Closed
jrose-signal wants to merge 112 commits into
mainfrom
jrose/boring-5.0.0
Closed

Merge in upstream v5.0.0#41
jrose-signal wants to merge 112 commits into
mainfrom
jrose/boring-5.0.0

Conversation

@jrose-signal

Copy link
Copy Markdown

No description provided.

ghedo and others added 30 commits September 26, 2025 13:46
Per BoringSSL's FIPS policy, its `main` branch is the "update branch"
for FedRAMP compliance's purposes.

This means that we can stop using a specific BoringSSL branch when
enabling FIPS, as well as a number of hacks that allowed us to build
more recent BoringSSL versions with an older pre-compiled FIPS modules.

This also required slightly updating the main BoringSSL submodule, as
the previous version had an issue when building with the FIPS option
enabled. This is turn required some changes to the PQ patch as well as
some APIs that don't seem to be exposed publicly, as well as changing
some paths in the other patches.

In order to allow a smooth upgrade of internal projects, the `fips-compat`
feature is reduced in scope and renamed to `legacy-compat-deprecated` so
that we can incrementally upgrade internal BoringSSL forks. In practice
this shouldn't really be something anyone else would need, since in
order to work it requires a specific mix of BoringSSL version and
backported patches.
SslStream::new() is fallible, but `SslStream::from_raw_parts()` and
`SslStreamBuilder::new()` now unwrap. Upstream has also deprecated the
`SslStreamBuilder`, maybe we should do the same.
The "kx-*" features control default key exchange preferences. Its
implementation requires disabling APIs for manually setting curve
preferences via `set_curves()` or `set_curves_list()`.

In practice, most teams need to be able to override default preferences
at runtime anyway, which means these features were never really used.
This commit gets rid of them, thereby reducing some complexity in the
API.
This is incompatible with the latest internal FIPS build. Namely, the
various group identifiers have been renamed since the previous version.
Instead of returning an `SslCurve`, just return the `u16` returned by
BoringSSL.
Add a wrapper for the `SSL_CTX_set_tlsext_ticket_key_cb`, which allows
consumers to configure the EVP_CIPHER_CTX and HMAC_CTX used for
encrypting/decrypting session tickets.

See https://docs.openssl.org/1.0.2/man3/SSL_CTX_set_tlsext_ticket_key_cb/
for more details.
Users can override the new default behavior in the usual way. The
expectation is that the build of BoringSSL they provide the feature set
implemented by the patch.
catap and others added 24 commits January 27, 2026 00:59
This enables rust bindings for BoringSSL's ML-KEM pq key encapsulation
including MLKEM758 and MLKEM1024
This method returns `None` for the GCM NIDs.

It appears to be implemented incorrectly: It first calls
`OBJ_nid2sn(nid)` to get the NID's short name, then calls
`EVP_get_cipherbyname(name)`. The documentation isn't clear as to
whether `name` should be the short or long name, but it appears to
expect the long name. At least, changing to `OBJ_nid2sn()` to
`OBJ_nid2ln()` makes the method work properly,

To fix this, this commit calls `EVP_get_cipherbynid()`, which is is more
direct.

Note that the method still returns `None` on the 3DES NID, but we're not
likely to encounter this one in practice.
This reverts commit a50a39f,
which interferes with CMake's own support for these variables,
at least how Signal has been using them.
@jrose-signal
jrose-signal marked this pull request as draft February 13, 2026 02:03
@jrose-signal

Copy link
Copy Markdown
Author

Closing, we'll go to 5.0.1 instead. #44

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.