Commit Graph

3446 Commits

Author SHA1 Message Date
Anthony Ramine 45f8589d48 Add mutable ex_data APIs for X509StoreContext 2025-06-05 01:06:09 +01:00
Anthony Ramine 15975ddde4
Ensure we call X509_STORE_CTX_cleanup on error path too (#360)
As X509_STORE_CTX_init may fail after setting some values
that should outlive the store context, we must ensure we
clean things up on its error path too.

We also know it's always ok to call X509_STORE_CTX_cleanupas X509_STORE_CTX_init starts with a call to it.
2025-06-02 16:40:44 +02:00
Anthony Ramine 6789a72fc0
Fix X509VerifyContextRef::set_verify_param (#358)
This method takes ownership of the given verify param.
2025-06-02 16:39:25 +02:00
Anthony Ramine 7a52fbbe99
Add X509VerifyParamRef::copy_from (#361) 2025-06-02 16:39:11 +02:00
James Larisch 2bc82e8d1c Add support for X509_STORE_CTX_get0_untrusted 2025-06-01 19:04:22 +01:00
0x676e67 0f2461ad00
sync upstream (#74)
* Add fips-precompiled feature to support newer versions of FIPS (#338)

Newer versions of FIPS don't need any special casing in our bindings,
unlike the submoduled boringssl-fips. In addition, many users currently
use FIPS by precompiling BoringSSL with the proper build tools and
passing that in to the bindings.

Until we adopt the Update Stream pattern for FIPS, there are two main
use cases:

1. Passing an unmodified, precompiled FIPS validated version of
   boringssl (fips-precompiled)

2. Passing a custom source directory of boringssl meant to be linked
   with a FIPS validated bcm.o. This is mainly useful if you carry
   custom patches but still want to use a FIPS validated BoringCrypto.
   (fips-link-precompiled)

This commit introduces the `fips-precompiled` feature and removes the
`fips-no-compat` feature.

* Release 4.16.0 (#341)

* feat(x509): Implement `Clone` for `X509Store` (#339)


* boring(x509): impl Clone of X509Store

* expose SSL_set_compliance_policy

* fix clippy error

* Use ubuntu-latest for all ci jobs

ubuntu 20.04 is now deprecated:
https://github.com/actions/runner-images/issues/11101

* add SslCurve::X25519_MLKEM768 constant

* Clippy

* Fix linking SystemFunction036 from advapi32 in Rust 1.87

* rustfmt ;(

* build: Fix the build for 32-bit Linux platform

* Update Cargo.toml

* boring(ssl): use `corresponds` macro in `add_certificate_compression_algorithm`

* Add `X509_STORE_CTX_get0_cert` interface

This method reliably retrieves the certificate the `X509_STORE_CTX` is
verifying, unlike `X509_STORE_CTX_get_current_cert`, which may return
the "problematic" cert when verification fails.

* Update bindgen from 0.70.1 -> 0.71.1.

* Revert "feat(x509): Implement `Clone` for `X509Store` (#339)" (#353)

* Revert "feat(x509): Implement `Clone` for `X509Store` (#339)"

This reverts commit 49a8d0906a.

See <https://github.com/cloudflare/boring/pull/120>.

* Ensure Clone is not added to X509Store

* Add comment about why X509Store must not implement Clone

---------

Co-authored-by: Kornel <kornel@cloudflare.com>

* Release 4.17.0 (#354)

* Add set_verify_param

* clippy fix

---------

Co-authored-by: Rushil Mehra <84047965+rushilmehra@users.noreply.github.com>
Co-authored-by: Shih-Chiang Chien <shih-chiang@cloudflare.com>
Co-authored-by: Rushil Mehra <rmehra@cloudflare.com>
Co-authored-by: Eric Rosenberg <eric_rosenberg@apple.com>
Co-authored-by: Kornel <kornel@cloudflare.com>
Co-authored-by: James Larisch <jlarisch@cloudflare.com>
Co-authored-by: Yury Yarashevich <yura.yaroshevich@gmail.com>
Co-authored-by: Anthony Ramine <123095+nox@users.noreply.github.com>
2025-05-30 11:15:39 +08:00
0x676e67 4fd641f79d clippy fix 2025-05-30 11:00:23 +08:00
0x676e67 6169bcd543 Merge remote-tracking branch 'upstream/master' into sync 2025-05-30 10:55:52 +08:00
James Larisch e99d162891 Add set_verify_param 2025-05-30 02:17:53 +02:00
Anthony Ramine 5e8aaf63f0
Release 4.17.0 (#354) 2025-05-28 11:53:09 +02:00
Anthony Ramine 560925293b
Revert "feat(x509): Implement `Clone` for `X509Store` (#339)" (#353)
* Revert "feat(x509): Implement `Clone` for `X509Store` (#339)"

This reverts commit 49a8d0906a.

See <https://github.com/cloudflare/boring/pull/120>.

* Ensure Clone is not added to X509Store

* Add comment about why X509Store must not implement Clone

---------

Co-authored-by: Kornel <kornel@cloudflare.com>
2025-05-27 18:19:35 +02:00
Yury Yarashevich 4ea82a2e1b Update bindgen from 0.70.1 -> 0.71.1. 2025-05-27 15:04:04 +01:00
James Larisch eefc7b7265 Add `X509_STORE_CTX_get0_cert` interface
This method reliably retrieves the certificate the `X509_STORE_CTX` is
verifying, unlike `X509_STORE_CTX_get_current_cert`, which may return
the "problematic" cert when verification fails.
2025-05-27 14:41:16 +01:00
0x676e67 6e35abb2cd boring(ssl): use `corresponds` macro in `add_certificate_compression_algorithm` 2025-05-26 08:51:37 -07:00
0x676e67 15281c77e2 Update Cargo.toml 2025-05-26 08:51:37 -07:00
0x676e67 eb48ab9a26 build: Fix the build for 32-bit Linux platform 2025-05-26 08:51:37 -07:00
Kornel 3ab8b53532 rustfmt ;( 2025-05-26 16:30:09 +01:00
Kornel 0327dd03c6 Fix linking SystemFunction036 from advapi32 in Rust 1.87 2025-05-26 16:30:09 +01:00
Kornel 23863ffd1b Clippy 2025-05-26 16:30:09 +01:00
0x676e67 7205960bc1
boring(ssl): add ZSTD to `CertificateCompressionAlgorithm` (#71) 2025-05-19 16:46:31 +08:00
0x676e67 9da3b7b44c
boring(ssl): use `corresponds` macro in `add_certificate_compression_algorithm` (#70) 2025-05-18 19:21:38 +08:00
0x676e67 9fb6143b11
chore(boring): deprecate legacy `CertCompressionAlgorithm` API (#69)
* chore(boring): deprecate legacy `CertCompressionAlgorithm` API

* ci: fix windows build
2025-05-18 18:55:08 +08:00
0x676e67 2b497506ef
chore(boring): deprecate `set_verify_cert_store_ref` on `SslContextBuilder` (#68) 2025-05-13 18:23:22 +08:00
Eric Rosenberg 9b34d3524b add SslCurve::X25519_MLKEM768 constant 2025-05-03 01:25:12 +09:00
0x676e67 493c0cb51b v4.15.13 2025-04-27 17:14:16 +08:00
hev fbad63bb8c
feat: Add basic support for LoongArch (#67) 2025-04-27 17:11:58 +08:00
0x676e67 cb25aadd4e v4.15.12 2025-04-23 12:55:37 +08:00
0x676e67 ee6d225ea3
ci: use ubuntu-latest (#66) 2025-04-23 12:54:54 +08:00
0x676e67 6458b54e6a
docs(boring): fix doc warning (#65) 2025-04-23 12:50:43 +08:00
dependabot[bot] c72c81aedd
build(deps): update brotli requirement from 7 to 8 (#64)
---
updated-dependencies:
- dependency-name: brotli
  dependency-version: 7.0.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-23 12:07:36 +08:00
Rushil Mehra 9c4ea22f72 Use ubuntu-latest for all ci jobs
ubuntu 20.04 is now deprecated:
https://github.com/actions/runner-images/issues/11101
2025-04-17 01:18:30 -07:00
Shih-Chiang Chien b29537e08f fix clippy error 2025-04-17 01:18:30 -07:00
Shih-Chiang Chien 220bedf239 expose SSL_set_compliance_policy 2025-04-17 01:18:30 -07:00
0x676e67 49a8d0906a
feat(x509): Implement `Clone` for `X509Store` (#339)
* boring(x509): impl Clone of X509Store
2025-04-07 18:05:27 +01:00
0x676e67 42d2398fcd
Create dependabot.yml 2025-04-05 19:43:37 +08:00
Rushil Mehra 20ad2665b2
Release 4.16.0 (#341) 2025-04-02 18:26:29 -07:00
Rushil Mehra 721b6fca2e
Add fips-precompiled feature to support newer versions of FIPS (#338)
Newer versions of FIPS don't need any special casing in our bindings,
unlike the submoduled boringssl-fips. In addition, many users currently
use FIPS by precompiling BoringSSL with the proper build tools and
passing that in to the bindings.

Until we adopt the Update Stream pattern for FIPS, there are two main
use cases:

1. Passing an unmodified, precompiled FIPS validated version of
   boringssl (fips-precompiled)

2. Passing a custom source directory of boringssl meant to be linked
   with a FIPS validated bcm.o. This is mainly useful if you carry
   custom patches but still want to use a FIPS validated BoringCrypto.
   (fips-link-precompiled)

This commit introduces the `fips-precompiled` feature and removes the
`fips-no-compat` feature.
2025-03-31 12:34:29 -07:00
0x676e67 ba1ee0dd48 v4.15.11 2025-03-21 20:38:44 +08:00
0x676e67 f55f9e1dd2
build: update workflows action (#61) 2025-03-21 19:36:03 +08:00
0x676e67 2576807382 chore: clippy fix 2025-03-21 18:28:13 +08:00
0x676e67 9c6c805947
Update issue templates 2025-03-21 18:23:14 +08:00
0x676e67 20f203cb57
Update ci.yml 2025-03-21 18:19:39 +08:00
0x676e67 dc306ba199
Delete .github/workflows/semgrep.yml 2025-03-21 18:19:23 +08:00
0x676e67 5ddc6ddb71 Update README.md 2025-03-21 18:18:48 +08:00
0x676e67 360c3949c8 build: fix doc test 2025-03-21 17:56:57 +08:00
0x676e67 6c74708e27 build: Ignore tests that bundle with the upstream boringssl binary 2025-03-21 17:54:31 +08:00
0x676e67 d72c6a4211
boring(x509): impl `Clone` of `X509Store` (#59) 2025-03-21 17:18:21 +08:00
0x676e67 cfe524c10b build: fix `pq-experimental` feature build 2025-03-21 16:56:19 +08:00
0x676e67 80d7385f78 Merge remote-tracking branch 'upstream/master' 2025-03-20 23:25:49 +08:00
0x676e67 94cd4e1498
chore(boring): simplify extensions sort order calculation (#58) 2025-03-20 23:15:54 +08:00