375 Commits

Author SHA1 Message Date
Brian Smith
af7c37f8af Enable FE25519_ADX Curve25519 base point mult. except on Windows. 2023-10-06 09:54:59 -07:00
Brian Smith
244a1dee00 Remove doc/link-to-readme.md.
The intended effect was to redirect people reading about *ring* on
crates.io to the GitHub-hosted README.md. However, the unintended effect
was that docs.rs is broken for the 0.17.0 release.
2023-10-05 22:45:41 -07:00
Brian Smith
096a99f426 Benchmarks: Add X25519 benchmark. 2023-10-04 20:59:49 -07:00
Brian Smith
d34858a918 0.17.0. 2023-10-02 01:18:18 -07:00
Brian Smith
93d1807dd0 0.17.0-beta.3 2023-10-02 01:18:18 -07:00
Brian Smith
851f9f339b 0.17.0-beta.2 2023-10-02 01:18:18 -07:00
Brian Smith
812592f5f3 0.17.0-beta.1 2023-10-02 01:18:18 -07:00
Brian Smith
e4a85afb58 ARM & Aarch64: Add ability to disable hardware crypto for testing. 2023-10-01 21:29:57 -07:00
Brian Smith
901441fd59 MSRV 1.61.0: Use cfg!(target_feature) for static AARCH64 feature detection. 2023-09-30 17:41:26 -07:00
Brian Smith
00da1cb1f7 Merge BoringSSL 'a905bbb': Consistently include BTI markers in every assembly file 2023-09-29 14:52:41 -07:00
Brian Smith
de138ee2e7
Revert "Document or remove some uses of unsafe" 2023-09-29 10:14:25 -07:00
Brian Smith
238ff8b191
Merge pull request #1657 from joshlf/unsafe-cleanup
Document or remove some uses of `unsafe`
2023-09-29 10:14:19 -07:00
Joshua Liebow-Feeser
4056fb9f6a Document or remove some uses of unsafe 2023-09-29 00:27:21 +00:00
Brian Smith
af45ee28f2 Add newly-added files to Cargo.toml to fix package job. 2023-09-28 15:04:48 -07:00
Alexis (Poliorcetics) Bourget
7bbc307f57 deps: Move from winapi to windows-sys
`winapi` is in maintenance mode and the new blessed way to access Windows APIs are the `windows`
and `windows-sys` crates. I don't think any types of `winapi` were exposed in the public API so
I used `windows-sys` since it has much faster compile times.
2023-09-26 19:40:45 -07:00
Brian Smith
5d8bdb6ca6 CI: Increase MSRV to 1.60. 2023-09-03 16:03:25 -07:00
Brian Smith
d0513bd767 Merge BoringSSL 53a87b7: ChaCha20-Poly1305 for Armv8 (AArch64). 2022-11-03 16:30:40 -07:00
Brian Smith
feae54128f Merge BoringSSL fa3fbda: P-256 assembly optimisations for Aarch64. 2022-11-02 13:15:58 -07:00
Brian Smith
e51d3c4eea Merge BoringSSL 661266e: Move CPU detection symbols to crypto/internal.h. 2022-10-31 16:31:35 -07:00
Brian Smith
6b0050f08c Merge BoringSSL 295b313: Rename CPU feature files with underscores. 2022-10-31 16:17:20 -07:00
Brian Smith
abe9529fc0 Remove documentation link.
The self-hosted documentation wasn't being kept up to date.
2022-10-29 11:16:41 -07:00
Brian Smith
a7b235162c Add MSRV to Cargo.toml. 2022-10-29 11:16:41 -07:00
Brian Smith
f5bd88cc0a Use the getrandom crate to implement ring::rand. 2022-10-29 11:14:38 -07:00
Brian Smith
371377d41d 2021 Edition: Remove now-redundant resolver = "2". 2022-10-20 23:03:50 -07:00
Brian Smith
6cf448ad49 Use Rust 2021 Edition. 2022-10-20 23:03:50 -07:00
Brian Smith
7386436fb7 Upgrade to critereon.rs 0.4.0 to shrink dev-dependencies tree.
Remove these 20 dev-dependencies:

  * bstr
  * crossbeam-channel
  * crossbeam-deque
  * crossbeam-epoch
  * crossbeam-utils
  * csv
  * csv-core
  * itoa
  * memchr
  * memoffset
  * num_cpus
  * plotters
  * plotters-backend
  * plotters-svg
  * rayon
  * rayon-core
  * regex-automata
  * scopeguard
  * serde_cbor
  * unicode-width

at the cost of adding these 8 dev-dependencies:

  * anes
  * ciborium
  * ciborium-io
  * ciborium-ll
  * clap_lex
  * hashbrown
  * indexmap
  * os_str_bytes
2022-10-20 09:41:56 -07:00
Brian Smith
c14c355f51 Use resolver v2. 2022-01-16 17:43:40 -08:00
Brian Smith
8d78cb2c01 wasm32: Add a wasm32_unknown_unknown_js feature to control use of web APIs.
Planning ahead for when WASI is to be supported, require the user to opt into
using web APIs for thw wasm32-unknown-unknown target with a new feature, since
wasm32-unknown-unknown could be used for either web or non-web environments.

Don't bother updating the tests to use this new flag, since the tests aren't
part of the "public API" of *ring*. When we add support for other WebAssembly
environments (e.g. WASI) we'll update the tests then.
2021-10-06 15:53:02 -07:00
Brian Smith
d97ae1fd08 wasm32: Make wasm32_c the default and only mode; remove the "wasm32_c" feature.
Always require a C compilare for wasm32, instead of trying to provide a subset
of the functionality.
2021-10-06 15:53:02 -07:00
Brian Smith
511740c29f RSA: Replace RsaSubjectPublicKey::{modulus,exponent} with rsa::Public::{Modulus,Exponent}::be_bytes().
This is a step towards removing the heap-allocated and usually-unnecessary
`public_key: RsaSubjectPublicKey` field. The new API allows the caller to
better control how it stores/allocates the component values. This also removes
a couple of infallible `unwrap()`s.

This is a step towards removing `io::Positive` from the public API.

This is a breaking API change.
2021-09-24 14:08:08 -07:00
Brian Smith
022f4dbe8e Bump libc version requirement. 2021-08-23 20:14:17 -07:00
Brian Smith
bf3e8582d6 Bump wasm-bindgen-test to 0.3.26. 2021-08-23 20:14:17 -07:00
Brian Smith
d77d152546 Bump web-sys to 0.3.51. 2021-08-23 20:14:17 -07:00
Brian Smith
e33675400a Bump once_cell to 1.8.0. 2021-08-23 20:14:17 -07:00
Brian Smith
9e6ea77bf1 Bump Criterion.rs version. 2021-08-23 20:14:17 -07:00
Jeremy Soller
dae1918124 Use /dev/urandom for SecureRandom on Redox 2021-08-16 12:54:43 -07:00
Brian Smith
ace62da913 Require cc-rs 1.0.69 or later to improve aarch64-pc-windows-msvc compatibility.
Alexander Ovchinnikov (@Alovchin91) wrote:
> [C]ould you please also upgrade cc to 1.0.69? This version contains fixes to
> find MSVC tools on Windows ARM.
2021-08-16 12:53:56 -07:00
Alexander Ovchinnikov
ceb5b90f6e Enable building and running on Windows ARM64
I agree to license my contributions to each file under the terms given at the top of each file I changed.

Co-authored-by: Marc-André Moreau <marcandre.moreau@gmail.com>
2021-08-16 12:28:42 -07:00
Brian Smith
539ac049a8 Upgrade spin to the latest version. 2021-08-15 15:30:54 -07:00
Brian Smith
188cc043f7 Use untrusted 0.9. 2021-07-13 15:54:42 -07:00
ComplexSpaces
b23e560b27 Port crypto-bench AEAD benchmarks to *ring*
I agree to license my contributions to each file under the terms given
at the top of each file I changed.

Add AEAD decryption benchmarks
2021-07-06 15:27:26 -07:00
Brian Smith
908eaf0322 Remove src/rsa/convert_nist_rsa_test_vectors.py from Cargo crate.
It isn't useful for it to be in the crate, as it isn't used in any part of the
build or tests.
2021-06-24 14:53:04 -07:00
Brian Smith
1ca07dd267 Cargo.toml: Use globs for *.rs and *_tests.txt so we don't have to list each one. 2021-06-24 14:53:04 -07:00
Brian Smith
1e18a1c292 RSA: Move verification::Key to public::Key.
Take a step towards having RSA keys support encryption/decryption
in addition to signing/verification.

No functional changes are intended.

Some documentation was moved around.
2021-06-24 12:58:14 -07:00
Joel Galenson
ae1e9dd64e Add missing test file to Cargo's includes.
This should allow tests to pass on the crates.io release.
2021-06-23 09:58:34 -07:00
Brian Smith
d32c304b3d Factor RsaPublicKeyComponents out of rsa::verification. 2021-06-03 11:33:11 -07:00
Brian Smith
7c9927e6b1 Cargo.toml: Clarify version number.
0.17.0-alpha.9 was released off the b/0.17.0-alpha.9 branch. Similarly for
0.17.0-alpha.10 on the b/0.17.0-alpha.10 branch.

Having the version number on the main branch say "0.17.0-alpha.9" or any
version number like that is confusing and misleading. We have to have a
version number, so use one that's clearer while we work on finishing
0.17.0.
2021-05-04 16:17:34 -07:00
Brian Smith
e898b00d53 Build: Derive FFI symbol prefix and FFI lib prefix from Cargo.toml "links".
Now "links" in Cargo.toml is the only thing that needs to be manually modified
when the prefix changes.

build.rs enforces that the package name and version are consistent with the
"links" field.
2021-05-03 16:28:56 -07:00
Brian Smith
badca90d14 Simplify assembly pre-generation mechanism.
Eliminate the extra Cargo.toml that was used just for this feature. It was
too error-prone to keep it in sync with the real Cargo.toml. Having one
Cargo.toml will allow us to reliably use the `CARGO_MANIFEST_LINKS` value
to keep the symbol prefix in sync with the `links` field in Cargo.toml in
the near future.
2021-05-03 13:36:20 -07:00
Brian Smith
7886603cee Use some variant of "ring core" instead of "GFp" as a prefix for everything.
"GFp_" isn't in the code at all anymore.
2021-05-02 22:09:07 -07:00