Commit Graph

188 Commits

Author SHA1 Message Date
0x676e67 8adb21b3b4
build: Fix 32-bit platform build (#51) 2025-02-14 02:10:21 +08:00
0x676e67 dded5d4e8c
Sync `Detailed error codes` and `Clean up boring_sys::init()` (#47)
* RTG-3333 Support X25519MLKEM768 by default, but don't sent it as client

X25519MLKEM768 is the standardised successor of the preliminary
X25519Kyber768Draft00. Latest browsers have switched to X25519MLKEM768.
Cloudflare supports both on the edge.

We've had support for X25519MLKEM768 in this crate for a while, but
didn't enable by default. We're now enabling serverside support by
default. We also let clients advertise support when set
to kx-client-pq-supported.

We don't enable support by default yet for clients set to
kx-client-pq-preferred, as that would cause an extra round-trip due to
HelloRetryRequest if the server doesn't support X25519MLKEM768 yet.

BoringSSL against which we build must support X25519MLKEM768, otherwise
this will fail.

* replace once_cell with LazyLock

We can drop the once_cell dependency since the same functionality is
implemented in std now.

Requires bumping MSRV to 1.80.

* fix manual_c_str_literals clippy warning

* chore: Fix docs on SslRef::replace_ex_data

* Detailed error codes

* Clean up boring_sys::init()

We don't need the workaround that was initially introduced for a bug in
openssl, and OPENSSL_init_ssl always calls into CRYPTO_library_init on
boringssl, so just call it explicitly.

---------

Co-authored-by: Bas Westerbaan <bas@cloudflare.com>
Co-authored-by: Alessandro Ghedini <alessandro@cloudflare.com>
Co-authored-by: Evan Rittenhouse <erittenhouse@cloudflare.com>
Co-authored-by: Kornel <kornel@cloudflare.com>
Co-authored-by: Rushil Mehra <rmehra@cloudflare.com>
2025-02-12 22:49:09 +08:00
Rushil Mehra a613d4b510 Clean up boring_sys::init()
We don't need the workaround that was initially introduced for a bug in
openssl, and OPENSSL_init_ssl always calls into CRYPTO_library_init on
boringssl, so just call it explicitly.
2025-02-11 17:48:58 -08:00
0x676e67 3c63f0b24e
fix: Fix `key share` patch (#46) 2025-02-11 17:18:10 +08:00
0x676e67 c6e390a8b8
feat: Add new binding functions to `ConnectConfiguration` (#42) 2025-02-07 12:08:49 +08:00
0x676e67 ed56d2c06a feat: Removal of `rpk` support 2025-02-07 11:50:05 +08:00
0x676e67 5d33987600
feat: Removal of `rpk` support (#41) 2025-02-07 11:36:39 +08:00
0x676e67 30c6bedc4d
feat: Add ALPS use new endpoint (#39) 2025-02-02 19:29:29 +08:00
0x676e67 bed5243775
feat: Add `kDHE` && `ffdhe2048`/`ffdhe3072` curves working implement (#36)
* RTG-3333 Support X25519MLKEM768 by default, but don't sent it as client

X25519MLKEM768 is the standardised successor of the preliminary
X25519Kyber768Draft00. Latest browsers have switched to X25519MLKEM768.
Cloudflare supports both on the edge.

We've had support for X25519MLKEM768 in this crate for a while, but
didn't enable by default. We're now enabling serverside support by
default. We also let clients advertise support when set
to kx-client-pq-supported.

We don't enable support by default yet for clients set to
kx-client-pq-preferred, as that would cause an extra round-trip due to
HelloRetryRequest if the server doesn't support X25519MLKEM768 yet.

BoringSSL against which we build must support X25519MLKEM768, otherwise
this will fail.

* feat: Add kDHE && ffdhe2048/ffdhe3072 curves working implement

* Update

---------

Co-authored-by: Bas Westerbaan <bas@cloudflare.com>
2025-01-22 13:08:20 +08:00
0x676e67 a9feffea83
docs: Fix docs build (#34) 2025-01-13 13:05:00 +08:00
0x676e67 b875e49daf
boring-sys: Optional SSL_OP_NO_RENEGOTIATION to disable client renegotiation extension (#33) 2025-01-10 16:16:41 +08:00
0x676e67 74c03ad71f Merge remote-tracking branch 'upstream/master' 2025-01-07 15:10:56 +08:00
Rushil Mehra 796afe1637 Allow dead_code instead of disabling clippy entirely for bindgen 2025-01-06 16:12:53 +00:00
Rushil Mehra c05a339911 Support linking with a runtime cpp library
As of https://boringssl-review.googlesource.com/c/boringssl/+/66288,
libssl allows a C++ runtime dependency. As such, we need to link with a
cpp runtime library. Implementation is inspired heavily from
54c956b2e6.

Before releasing this change, we'll need to figure out a way to support
this for windows.
2025-01-06 16:08:33 +00:00
0x676e67 0e6b794ead
feat(boring): Add optional disable `PSK_DHE_KE` (#32) 2025-01-05 11:54:25 +08:00
0x676e67 f8e01e3d0c
feat: Expose extended sorting from indices (#29) 2024-12-20 14:18:16 +08:00
0x676e67 66cc25a270
feat: Add setup extension permutation (#28) 2024-12-19 23:21:31 +08:00
0x676e67 292b2a1513
refactor: refactor `key_shares` length limit (#27) 2024-12-19 18:17:40 +08:00
0x676e67 928968947a
boring-sys: Add TLS extension zstd cert compression (#24) 2024-12-18 19:34:06 +08:00
0x676e67 b4c46bb8a1
patch: Add enable three `key_shares` limit (#23) 2024-12-18 18:58:41 +08:00
0x676e67 abd65310ba
patch: Add option enable delegated_credentials (#22) 2024-12-18 16:32:38 +08:00
0x676e67 39914a641c
patch: Add option enable record_size_limit (#21) 2024-12-18 14:57:23 +08:00
0x676e67 6ef0ca379e
boring: Add SslCurve `FFDHE2048`/`FFDHE3072` NID support (#20) 2024-12-18 13:14:02 +08:00
0x676e67 30cadfb1eb
boring: Add SslCurve `FFDHE2048`/`FFDHE3072` support (#19) 2024-12-17 23:22:56 +08:00
0x676e67 0ee30f7487
boring: update old ciphers patch (#18) 2024-12-17 20:12:33 +08:00
Paul Mabileau 7ac0d2105c Fix Windows build
Only with this does it work for us.

Signed-off-by: Paul Mabileau <paul.mabileau@harfanglab.fr>
2024-11-27 12:56:03 -08:00
0x676e67 63d01c439a
Fix Windows build (#13) 2024-11-27 19:47:44 +08:00
0x676e67 6b5844021d rename rboring-sys to boring-sys2 2024-11-15 10:42:09 +08:00
0x676e67 6768d3c437
sync upstream (#12)
* Release 4.10.3 (#280)

* Create semgrep.yml

Creating Semgrep.yml file - Semgrep is a tool that will be used to scan Cloudflare's public repos for Supply chain, code and secrets. This work is part of Application & Product Security team's initiative to onboard Semgrep onto all of Cloudflare's public repos.

In case of any questions, please reach out to "Hrushikesh Deshpande" on cf internal chat.

* Add "fips-compat" feature (#286)

This adds a feature to build against a BoringSSL version compatible with
the current boringssl-fips, but _without_ actually enabling the `fips`
feature.

This can be useful to use with `fips-link-precompiled` while using a
custom BoringSSL version based on the older FIPS branch.

* boring-sys: include HPKE header file for bindgen

BoringSSL doesn't expose these APIs for FIPs builds, so we gate them
here as well

* Release 4.11.0

* Add `set_cert_verify_callback` (`SSL_CTX_set_cert_verify`)

Add a wrapper for `SSL_CTX_set_cert_verify`, which allows consumers to
override the default certificate verification behavior.

The binding resembles `SSL_CTX_set_verify`'s.

See
https://docs.openssl.org/master/man3/SSL_CTX_set_cert_verify_callback/
for more details.

* Skip bindgen 0.70's layout tests before Rust 1.77

* (ci): brew link x86 toolchain for macos13 runner

It seems we need to manually symlink the x86_64-unknown-linux-gnu
toolchain for the macos13 runner. Also, we don't need to overwrite the
python version anymore

Fixes https://github.com/cloudflare/boring/issues/285

* feat(boring): Add SSL_CURVE_X25519_MLKEM768 curve binding

---------

Co-authored-by: Rushil Mehra <84047965+rushilmehra@users.noreply.github.com>
Co-authored-by: Hrushikesh Deshpande <161167942+hrushikeshdeshpande@users.noreply.github.com>
Co-authored-by: Alessandro Ghedini <alessandro@cloudflare.com>
Co-authored-by: Evan Rittenhouse <erittenhouse@cloudflare.com>
Co-authored-by: James Larisch <jlarisch@cloudflare.com>
Co-authored-by: Jordan Rose <jrose@signal.org>
Co-authored-by: Rushil Mehra <rmehra@cloudflare.com>
2024-11-03 21:13:37 +08:00
Jordan Rose 3044e9ba98 Skip bindgen 0.70's layout tests before Rust 1.77 2024-10-22 16:53:40 -07:00
Evan Rittenhouse 80e3aab37d boring-sys: include HPKE header file for bindgen
BoringSSL doesn't expose these APIs for FIPs builds, so we gate them
here as well
2024-10-17 10:18:52 -07:00
0x676e67 3342c9dffe Update docs link 2024-09-22 08:00:26 +08:00
0x676e67 b0fe60dcf6 Merge remote-tracking branch 'upstream/master' 2024-09-22 07:57:47 +08:00
Yuchen Wu 0596b2dcab
Set MSRV to 1.70 (#279)
With the bindgen 0.70 upgrade, the default rust target is set to be 1.77,
which becomes the de facto MSRV of boring-sys since the change.

This change makes sure that the MSRV of boring-sys is kept at 1.70,
which is the same as that of bindgen.
2024-09-21 21:42:39 +02:00
Bas Westerbaan b1a7434c19 boring-pq.patch Fix by not updating crypto_test_data.cc
crypto_test_data.cc is not included anymore since 2475ef386b
2024-09-19 00:17:37 +02:00
Anthony Ramine 193bf3b9d7
Implement optional Hyper 1 support in hyper-boring (#246) 2024-09-18 13:24:35 +02:00
Bas Westerbaan 6d3639f173 Add post-quantum key agreement X25519MLKEM768
This is the successor of X25519Kyber768Draft00.

Spec:

https://datatracker.ietf.org/doc/draft-kwiatkowski-tls-ecdhe-mlkem/02/

IANA has assigned the codepoint.

https://www.iana.org/assignments/tls-parameters/tls-parameters.xhtml#tls-parameters-8

Upstream BoringSSL support landed in.

7fb4d3da50

The version of BoringSSL we patch does not include it, so we add it manually.

Chrome and Firefox are planning to enable in October.

This PR is based on the IPD-Wing patch reviewed here:

https://github.com/cloudflare/boring/pull/243

There are two changes. First we simplify the patch a bit as we do not
need IPD-Wing. Secondly, we perform the encapsulation key check, which
was a last minute addition of NIST. We perform this check also for Kyber.
2024-09-18 12:00:27 +02:00
Bas Westerbaan 2c0a14253a Revert "PQ: fix timing sidechannels and add IPDWing"
For TLS, early adopters prefer X25519MLKEM768. Remove IPDWing in
preparation for adding X25519MLKEM768.

https://datatracker.ietf.org/doc/draft-kwiatkowski-tls-ecdhe-mlkem/

This reverts commit 4725a930d5.
2024-09-18 12:00:27 +02:00
0x676e67 9053b5d905
chore(boring-sys): Fix git apply patch on Windows (#261)
* chore(boring-sys): Fix git apply patch on Windows

* cargo fmt --all
2024-08-14 02:53:57 -07:00
0x676e67 9523ac82c9
Merge patch (#8) 2024-08-12 09:56:42 +08:00
Rushil Mehra 5dce4d331b Ignore clippy / rustfmt on autogenerated code 2024-07-30 12:28:38 -07:00
Rushil Mehra 6e9ba1cb96 Clean up legacy const_fn feature gates 2024-07-30 12:28:38 -07:00
Bas Westerbaan 4725a930d5 PQ: fix timing sidechannels and add IPDWing
Fix three potential timing sidechannels. These don't affect ephemeral
usage of Kyber as in TLS, but it's good practice to get rid of them anyway.

Also adds IPDWing, a preliminary version of X-Wing using the initial public
draft (IPD) of ML-KEM. Don't use it.
2024-07-08 19:47:43 +01:00
Liu Dingming b96d2b88a4 Enable layout tests on iOS target 2024-03-24 11:11:05 -07:00
Isaiah Becker-Mayer ba85412229 Removes vestigial build script 2024-02-26 13:25:46 +01:00
Rushil Mehra d3a42b0aeb Fix building with BORING_BSSL_PATH / BORING_BSSL_FIPS_PATH
When passing BORING_BSSL_FIPS_PATH, you need to add /lib/ to the search
path, and when passing BORING_BSSL_PATH you need to add /crypto/ and
/ssl/ to the search path.
2024-02-02 10:23:41 -08:00
Rushil Mehra 5aed467dcb Fix building with non bazel commits of boringssl
We need to add `/build/crypto` and `/build/ssl` to the library search
path to handle the case where we pass `BORING_BSSL_SOURCE_PATH` when
building without enabling any fips features. Otherwise, non bazel
commits will not work because `/build/` itself will not contain any
crypto libraries to link with
2024-02-02 14:56:55 +00:00
Anthony Ramine a8dea4a22c Introduce X509CheckFlags::UNDERSCORE_WILDCARDS 2024-01-02 15:37:36 +01:00
Chris Eager 59ef71327f Remove unused target_env from boring-sys build config 2023-12-14 13:25:47 +01:00
Jordan Rose 44f8f72a16 boring-sys: Blocklist max_align_t in bindgen
https://github.com/rust-lang/rust-bindgen/issues/1823
2023-12-14 13:25:47 +01:00
Jordan Rose 5dc531a38c boring-sys: Don't check for MSVC with target_env
x86_64-pc-windows-gnu is identified as `target_env = "msvc"` too,
but doesn't use the Visual Studio CMake generator.
2023-12-14 13:25:47 +01:00
Jordan Rose af0c36a22f boring-sys: Don't use CMake cross-compilation for macOS->iOS
(or macOS->macOS)
2023-11-30 15:03:23 +01:00
Anthony Ramine d7a13a8468 Fix clippy lint 2023-11-16 19:47:16 +01:00
Anthony Ramine 7434e35faa Introduce BORING_BSSL_SYSROOT and BORING_BSSL_EXTERNAL_TOOLCHAIN
These variables let us configure CMAKE_SYSROOT and
CMAKE_{C,CXX,ASM}_EXTERNAL_TOOLCHAIN from env variables
without needing an error-prone custom toolchain file.

Most users won't need BORING_BSSL_EXTERNAL_TOOLCHAIN, but some
packages (such as Homebrew package
messense/macos-cross-toolchains/x86_64-unknown-linux-gnu) don't
install the sysroot at the root of the GCC installation, so clang-12
cannot find crt1.o and crti.o.

Finally, we also set up CMAKE_CROSSCOMPILING and
CMAKE_{C,CXX,ASM}_COMPILER_TARGET to make cross compilation work
with compilers that have cross-compiling drivers (i.e. clang).

We can now cross build boring-sys from macOS to Linux with
fips feature turned on:

brew tap nox/misc
brew install llvm@12.0.0
export PATH="$(brew --prefix llvm@12.0.0)/bin:$PATH"

brew tap messense/macos-cross-toolchains
brew install x86_64-unknown-linux-gnu
export BORING_BSSL_FIPS_EXTERNAL_TOOLCHAIN="$(brew --prefix x86_64-unknown-linux-gnu)/toolchain"
export BORING_BSSL_FIPS_SYSROOT="$BORING_BSSL_FIPS_EXTERNAL_TOOLCHAIN/x86_unknown-linux-gnu/sysroot"

cargo build --target x86_64-unknown-linux-gnu -p boring-sys --features fips
2023-10-26 11:31:47 +01:00
Anthony Ramine ba0ea33ab4 Check for CMAKE_TOOLCHAIN_FILE when creating cmake config
We don't do anything fancy anymore for non-cross builds
and when a specific CMAKE_TOOLCHAIN_FILE is specified.
2023-10-26 11:31:47 +01:00
Anthony Ramine 80b97c8318 Introduce target-specific env vars
The logic is stolen from cmake-rs, and it is important to
follow it as we will need to look for CMAKE_TOOLCHAIN_FILE
the same way cmake-rs does.

When checking for env variable BORING_BSSL_PATH during a
cross build for target x86_64-unknown-linux-gnu, boring-sys
build script will attempt to read:

  BORING_BSSL_PATH_x86_64-unknown-linux-gnu
  BORING_BSSL_PATH_x86_64_unknown_linux_gnu
  TARGET_BORING_BSSL_PATH
  BORING_BSSL_PATH
2023-10-26 11:31:47 +01:00
Anthony Ramine d8c2122c73 Continue looping if candidate cxx isn't found in verify_fips_clang_version
A basic LLVM 12 build provides clang-12 but not clang++-12, but
it does provide both clang and clang++, so we shouldn't hard fail
when first checking for clang-12 and clang++-12.
2023-10-26 11:31:47 +01:00
Anthony Ramine 9a0bd94f99 Replace feature no-patches with BORING_BSSL{,_FIPS}_ASSUME_PATCHED
Feature no-patches is ever only useful when setting other env variables
BORING_BSSL{,_FIPS}{,_SOURCE}_PATH, and it has no impact on the APIs
provided by any of the boring crates, so we may as well make it an env
variable itself so downstream users have less features to propagate
across their own crate graph.
2023-10-23 15:06:23 +02:00
Anthony Ramine 7ddb106c20 Introduce a new set of env variables for FIPS-like builds
Builds using feature fips or fips-link-precompiled now
read variables prefixed by BORING_BSSL_FIPS_ instead of
BORING_BSSL_. This helps complex builds where build dependencies
also use boring, where we may not want to use fips there.

Without those separate variables, the boring build for the
build dependencies end up relying on e.g. BORING_BSSL_PATH,
causing errors if this path is a boring checkout intended for
fips builds, while the fips feature isn't enabled for
the build dependency.
2023-10-23 12:28:12 +02:00
Anthony Ramine bc095478fc Use prefix BORING_BSSL_ for all boringssl env variables
This means BORING_SSL_PRECOMPILED_BCM_O is now
BORING_BSSL_PRECOMPILED_BCM_O.

Prefix BORING_BSSL_ has been chosen because that's the
one that is used the most among all the variables
the build script uses.
2023-10-23 12:28:12 +02:00
Anthony Ramine ebea825d18 Don't read BORINGSSL_BUILD_DIR anymore
It's actually unused.
2023-10-23 12:28:12 +02:00
Anthony Ramine 6b52c1e93c Don't use env::current_dir in build script
The current directory from a build script executed by cargo
is always the manifest dir, so we may as well only use
the manifest dir.
2023-10-23 12:28:12 +02:00
Anthony Ramine 0d25d74cd6 Introduce struct Config in build script
Using a struct improves navigation of the build script,
as we can rely on rust-analyzer to help us check how
a feature flag or an environment variable is used,
as opposed to grepping for multiple env::var calls
or #[cfg] attributes.

This commit also removes some obsolete blocks of code
related to the now defunct ndk-old-gcc and fuzzing features.
2023-10-23 12:28:12 +02:00
Manuel Olguín Muñoz bdbef2003f tweaks for ergonomic linking 2023-09-13 12:38:03 +01:00
Christopher Patton 2fa3d96966 Use features to set key exchange preferences
Overwrite boringSSL's default key exchange preferences with safe
defaults using feature flags:

* "kx-pq-supported" enables support for PQ key exchange algorithms.
  Classical key exchange is still preferred, but will be upgraded to PQ
  if requested.

* "kx-pq-preferred" enables preference for PQ key exchange,
  with fallback to classical key exchange if requested.

* "kx-nist-required" disables non-NIST key exchange.

Each feature implies "kx-safe-default". When this feature is enabled,
don't compile bindings for `SSL_CTX_set1_curves()` and `SslCurve`. This
is to prevent the feature flags from silently overriding curve
preferences chosen by the user.

Ideally we'd allow both: that is, use "kx-*" to set defaults, but still
allow the user to manually override them. However, this doesn't work
because by the time the `SSL_CTX` is constructed, we don't yet know
whether we're the client or server. (The "kx-*" features set different
preferences for each.) If "kx-sfe-default" is set, then the curve
preferences are set just before initiating a TLS handshake
(`SslStreamBuilder::connect()`) or waiting for a TLS handshake
(`SslStreamBuilder::accept()`).
2023-09-01 14:21:35 -07:00
Ivan Nikulin 5d6ca7e19c Introduce `no-patches` feature 2023-09-01 09:28:27 +01:00
Eliza Weisman 2345c2f988 boring-sys: include all files needed to build FIPS
This commit modifies the Cargo `include` field for `boring-sys` to
include all the files necessary to actually build the FIPS-certified
revision of BoringSSL. Currently, some of these files are missing (see
#157 for details on this).

This branch improves on my previous approach in PR #158, which switched
from using a Cargo `include` to a Cargo `exclude`. Using `exclude`
rather than `include` resulted in a much larger crates.io package, but
at the time, I thought this was less likely to result in breakage in the
future, because I was concerned about the inability to verify that the
set of excludes/includes can build a new pinned `boringssl` git revision
without having to actually publish a crates.io release.

However, as @nox pointed out in [this comment][1], `cargo package` can
be used to verify a build with the `exclude`s/`include`s applied. This
branch therefore adds `cargo package` steps to CI that check that the
package can actually be built. This way, we are able to make a much
smaller change to the included files, resulting in a smaller package
published to crates.io.

On this branch, the package is 6.7MiB compressed, which is not much
larger than it was previously:

```
    Finished dev [unoptimized + debuginfo] target(s) in 55.65s
    Packaged 1851 files, 33.7MiB (6.7MiB compressed)
```

Fixes #157
Closes #158

[1]: https://github.com/cloudflare/boring/pull/158#issuecomment-1693067112,
2023-08-30 14:54:18 +01:00
Ivan Nikulin 011d500460 Separate `fips` and `fips-link-precompiled` features.
Make the later compatible with `rpk` feature.
2023-08-30 11:41:20 +01:00
Ivan Nikulin edfe18b196 Add missing cmake files to the package 2023-08-05 14:32:02 +01:00
Manuel Olguín Muñoz 57e54be907 Fix missing .trim() when verifying FIPS module name 2023-08-05 13:54:26 +01:00
Ivan Nikulin 308f0405bd Release 3.0.2 2023-08-03 13:38:59 +01:00
Ivan Nikulin 7fd29555b6 Fix feature gates for fips-link-precompiled 2023-08-03 13:38:59 +01:00
Ivan Nikulin 959d7c034e Reduce release bundle size by excluding PQ test data 2023-08-01 18:36:51 +01:00
Nathan Mittler 74fd7a8ce4 Adding hmac.h to included headers
This was originally going to be fixed by #101, however that PR was closed and superseded by #117, which was missing this fix.

The original problem was caused by #97, which updated boringssl to a version that included [a change that removed hmac.h from ssl.h](05b360d797).

This PR adds an include for hmac.h, so it is again available through boring-sys.
2023-08-01 19:13:19 +02:00
Ivan Nikulin 2475ef386b Reduce release bundle size by excluding PQ test data 2023-08-01 17:51:44 +01:00
Ivan Nikulin 33e3d756ff Fix builds for features that require git patches
Previously we were building from the deps directory with submodules. For publishing we were copying files in sumbodules into the package. With this we were making the package directory dirty with build artifacts and applied patches.

This commit change the build script's behaviour: sources are now copied to the output directory and then boringssl is built from there.

In addition, this commit adds files that were missing from the package for building with patches.
2023-08-01 17:33:29 +01:00
Ivan Nikulin 6435c5b8d5 Fix publishing 2023-08-01 11:32:20 +01:00
Ivan Nikulin c12bfc21f6 Release 3.0.0 2023-07-28 14:07:22 +01:00
Ivan Nikulin 4761cf7805
Merge pull request #84 from signalapp/macos-cross-compile
boring-sys: Handle cross-compiling macOS targets
2023-07-28 13:21:04 +01:00
Ivan Nikulin 4e190ad00c
Merge pull request #95 from signalapp/libsignal-arm
boring-sys: Add support for cross-compiling to Linux ARM(v7)
2023-07-28 13:20:32 +01:00
Jordan Rose a39f0c78ee boring-sys: Handle cross-compiling macOS targets
...such as compiling for Apple Silicon on an Intel Mac.
2023-07-27 13:17:40 -07:00
morph027 bb5caa43a2 boring-sys: Add support for Linux ARM(v7)
Signed-off-by: morph027 <stefan.heitmueller@gmx.com>
2023-07-27 13:15:53 -07:00
Jordan Rose 32feb4f958 boring-sys: Update Android NDK sysroot path
This longer path (inside the prebuilt toolchain included in the NDK)
has been the preferred sysroot since NDK r19. Newer NDKs no longer
have a top-level "sysroot" directory at all.
2023-07-27 13:12:57 -07:00
Ivan Nikulin d4ddd16ee2 Add fips-link-precompiled feature 2023-07-26 14:35:40 +01:00
Alessandro Ghedini f772338238 Allow specifying a custom BoringSSL source directory 2023-07-14 10:47:37 +01:00
Ivan Nikulin 0b542999d4 Address review comments 2023-07-10 14:00:52 +01:00
Ivan Nikulin d59d170c4d Update docs 2023-07-10 12:29:30 +01:00
Ivan Nikulin d1ee9bfd86 Use workspace metadata for crates 2023-07-10 11:38:18 +01:00
Ivan Nikulin c4e8a94a69 Add RPK and PQ crypto features 2023-07-07 13:50:36 +01:00
Ivan Nikulin 0dd85d187b
Merge pull request #117 from nox/bump-boringssl
Update boringssl to latest upstream commit (fixes #100)
2023-05-11 16:23:28 +01:00
Ivan Nikulin 561d786c10
Merge pull request #97 from PiotrSikora/boringcrypto_4407
Update BoringCrypto to FIPS 140-2 certificate 4407.
2023-05-11 16:22:25 +01:00
Piotr Sikora 902e7d0c92 Update BoringCrypto to FIPS 140-2 certificate 4407.
Signed-off-by: Piotr Sikora <piotr@aviatrix.com>
2023-05-09 10:37:32 +02:00
Anthony Ramine 6274f70726 Update boringssl to latest upstream commit
Notable commits that cause code changes here:

X509 fields notBefore and notAfter need to be specified
https://boringssl-review.googlesource.com/c/boringssl/+/49349

X509ReqBuilder only accepts X509v1 now
https://boringssl-review.googlesource.com/c/boringssl/+/52605

Some functions switched from int to size_t
https://boringssl-review.googlesource.com/c/boringssl/+/54985

CECPQ2 support was dropped
https://boringssl-review.googlesource.com/c/boringssl/+/58645

This is a breaking change.
2023-05-09 10:28:10 +02:00
Anthony Ramine 530db8841b Bump bindgen to 0.65.1 2023-05-05 11:58:47 +02:00
Anthony Ramine 74b0cc0da7 Fix lints 2023-03-27 13:15:12 +02:00
Ivan Nikulin 3059ba6e10
Merge pull request #78 from signalapp/aarch64-cross-compilation
Add minimal cross-compilation support for Windows and AArch64 Linux
2022-09-27 16:14:52 +01:00
Joshua Nelson da2c13e761 Update changelogs and bump version numbers 2022-09-16 13:03:26 -05:00
Joshua Nelson bd4f8d58ef Fix clippy warnings 2022-09-16 12:13:55 -05:00
Jordan Rose a117901fe0 boring-sys: Use the Android NDK sysroot when running bindgen 2022-07-25 19:31:59 -04:00
Jordan Rose 3bbb1b94b6 Add minimal cross-compilation support for Windows and AArch64 Linux
Cross-compiling to AArch64 Linux can be done with a CMake toolchain
file, along with setting the correct compiler and include paths in the
environment.

Cross-compiling from X64 Windows to ARM64 Windows doesn't look at the
toolchain at all, because CMake + Visual Studio can already
cross-compile. Unfortunately, the Visual Studio CMake generator
doesn't set CMAKE_SYSTEM_PROCESSOR, which is what the BoringSSL
CMakeLists.txt is looking at to choose the architecture. For now,
disable the use of assembly when cross-compiling on Windows (assuming
that the Visual Studio generator will be used there).
2022-06-27 18:01:55 -07:00