Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
483 changes: 483 additions & 0 deletions .github/workflows/publish.yml

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ members = [
resolver = "2"

[workspace.package]
version = "5.3.0"
version = "5.4.0"
rust-version = "1.85"
repository = "https://github.com/cloudflare/boring"
edition = "2021"
Expand All @@ -20,9 +20,9 @@ tag-prefix = ""
publish = false

[workspace.dependencies]
boring-sys = { version = "5.3.0", path = "./boring-sys", default-features = false }
boring = { version = "5.3.0", path = "./boring", default-features = false }
tokio-boring = { version = "5.3.0", path = "./tokio-boring", default-features = false }
boring-sys = { version = "5.4.0", path = "./boring-sys", default-features = false }
boring = { version = "5.4.0", path = "./boring", default-features = false }
tokio-boring = { version = "5.4.0", path = "./tokio-boring", default-features = false }

bindgen = { version = "0.72.0", default-features = false, features = ["runtime", "prettyplease"] }
bitflags = "2.9"
Expand Down
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,18 @@ and [Raw Public Key](https://docs.rs/boring/latest/boring/ssl/struct.SslRef.html
- hyper HTTPS connector: <https://docs.rs/hyper-boring>
- FFI bindings: <https://docs.rs/boring-sys>

## crates.io releases

A release PR contains exactly one commit that changes the workspace version, with all four published crates resolving to that version. The PR is merged into `master` using the repository's rebase-and-merge strategy, and its post-rebase merge commit must remain reachable from `master` when the release is started.

The release workflow is run from `master` through **Actions → Publish to crates.io** with the merged PR number and expected version, without the `v` prefix. It verifies the PR, merge commit, and crate versions before creating the immutable tag and publishing `boring-sys`. Once the first crate succeeds, it creates or reuses a non-latest GitHub Release and publishes `boring`, `tokio-boring`, and `hyper-boring` in dependency order. The GitHub Release is updated after each crate succeeds with a link to its crates.io version.

The annotated `v<version>` tag is created before publication as the release's immutable anchor. A partially completed release remains a non-latest GitHub Release and can be rerun with the same inputs; already-published crates remain linked in the Release body. After all crates publish successfully, the GitHub Release becomes the latest release. Pushing a tag alone does not publish a release. The `crates-io` environment policy permits `master` and retains its required reviewers.

On a rerun, an existing non-yanked crate version is accepted only when its crates.io checksum matches the archive generated from the release commit. A checksum mismatch stops the release rather than associating an artifact from another source with this release.

Versions with a prerelease component, such as `5.4.0-rc.1`, are marked as GitHub prereleases and never become the repository's Latest release.

# Upgrading from `boring` v4

* First update to boring 4.22 and ensure it builds without any deprecation warnings.
Expand Down
22 changes: 22 additions & 0 deletions RELEASE_NOTES
Original file line number Diff line number Diff line change
@@ -1,3 +1,25 @@
5.4.0
- 2026-10-30 Add unchecked DER certificate setters
- 2026-10-28 Update to boringssl 0.20261020.0 with ML-DSA by default
- 2026-10-23 Add Asn1IntegerRef::to_der_contents
- 2026-10-19 Make crates.io publishing a guarded manual release (#541)
- 2026-03-27 Constants for rust-openssl compat
- 2026-03-27 `ASN1_INTEGER_*`, `BN_*` functions
- 2026-10-14 Add crates.io trusted publishing (#535)

5.3.0
- 2026-10-14 Add action-aware certificate selection callbacks
- 2026-10-14 Back-compat shims for v4
- 2026-10-14 Add X509Ref::check_host_with_flags (fixes #530)
- 2026-10-09 boring-sys: exclude non-BoringSSL symbols from bindings
- 2026-09-30 Fix tests failures related to upstream X509_V_FLAG_TRUSTED_FIRST change
- 2026-09-30 Update to boringssl 0.20260929.0
- 2026-08-28 RTG-5132 Enable X25519MLKEM768 in FIPS compliance profile
- 2026-08-20 RTG-5132 Bump BoringSSL
- 2026-09-22 Add native HKDF bindings
- 2026-08-14 Semver compat for nonce mutability issue
- 2026-06-25 aead: require &mut self for seal/open and add TLS AEAD variants

5.2.0
- 2026-10-14 Add action-aware certificate selection callbacks, including ECH fallback
- 2026-05-21 Export `DEP_BORINGSSL_VERSION_MAJOR` var
Expand Down
36 changes: 33 additions & 3 deletions boring-sys/build/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ fn get_boringssl_source_path(config: &Config) -> &Path {
println!("cargo:warning=fetching boringssl git submodule");

run_command(
Command::new("git")
git_command()
.args(["submodule", "update", "--init", "--recursive"])
.arg(&submodule_path),
)
Expand Down Expand Up @@ -488,7 +488,7 @@ fn ensure_patches_applied(config: &Config) -> io::Result<()> {

// NOTE: init git in the copied files, so we can apply patches
if !has_git {
run_command(Command::new("git").arg("init").current_dir(src_path))?;
run_command(git_command().arg("init").current_dir(src_path))?;
}

if config.features.allow_crl_extensions_bad_version {
Expand Down Expand Up @@ -540,7 +540,7 @@ fn apply_patch(config: &Config, patch_name: &str) -> io::Result<()> {
}

run_command(
Command::new("git")
git_command()
.args(&args)
.arg(cmd_path)
.current_dir(src_path),
Expand All @@ -549,6 +549,36 @@ fn apply_patch(config: &Config, patch_name: &str) -> io::Result<()> {
Ok(())
}

/// Repository-local variables, as listed by `git rev-parse --local-env-vars`.
///
/// Git sets these when it runs hooks, so a build started from a hook would
/// otherwise run `git` against the caller's repository instead of the BoringSSL sources.
const GIT_LOCAL_ENV_VARS: &[&str] = &[
"GIT_ALTERNATE_OBJECT_DIRECTORIES",
"GIT_CONFIG",
"GIT_CONFIG_PARAMETERS",
"GIT_CONFIG_COUNT",
"GIT_OBJECT_DIRECTORY",
"GIT_DIR",
"GIT_WORK_TREE",
"GIT_IMPLICIT_WORK_TREE",
"GIT_GRAFT_FILE",
"GIT_INDEX_FILE",
"GIT_NO_REPLACE_OBJECTS",
"GIT_REPLACE_REF_BASE",
"GIT_PREFIX",
"GIT_SHALLOW_FILE",
"GIT_COMMON_DIR",
];

fn git_command() -> Command {
let mut command = Command::new("git");
for var in GIT_LOCAL_ENV_VARS {
command.env_remove(var);
}
command
}

fn run_command(command: &mut Command) -> io::Result<Output> {
let out = command.output().map_err(|e| {
io::Error::new(
Expand Down
2 changes: 1 addition & 1 deletion boring-sys/deps/boringssl
Submodule boringssl updated 293 files
Loading
Loading