diff --git a/.github/workflows/elliptic-curve.yml b/.github/workflows/elliptic-curve.yml index aafbab136..61381f529 100644 --- a/.github/workflows/elliptic-curve.yml +++ b/.github/workflows/elliptic-curve.yml @@ -102,6 +102,8 @@ jobs: MIRIFLAGS: "-Zmiri-symbolic-alignment-check -Zmiri-strict-provenance" steps: - uses: actions/checkout@v6 - - uses: dtolnay/rust-toolchain@nightly + - uses: dtolnay/rust-toolchain@stable + with: + toolchain: nightly-2026-02-11 # pinned due to rust-lang/miri#4855 - run: rustup component add miri && cargo miri setup - run: cargo miri test --all-features diff --git a/Cargo.lock b/Cargo.lock index d4de953d9..575b405d8 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -222,8 +222,8 @@ dependencies = [ "block-buffer", "const-oid", "crypto-common", + "ctutils", "sha2", - "subtle", "zeroize", ] diff --git a/digest/Cargo.toml b/digest/Cargo.toml index 4d9f224b6..252d03dee 100644 --- a/digest/Cargo.toml +++ b/digest/Cargo.toml @@ -17,9 +17,9 @@ common = { version = "0.2", package = "crypto-common" } # optional dependencies block-buffer = { version = "0.11", optional = true } -subtle = { version = "2.4", default-features = false, optional = true } blobby = { version = "0.4", optional = true } const-oid = { version = "0.10", optional = true } +ctutils = { version = "0.4", optional = true } zeroize = { version = "1.7", optional = true, default-features = false } [dev-dependencies] @@ -28,7 +28,7 @@ sha2 = "0.11.0-rc.5" [features] default = ["block-api"] block-api = ["block-buffer"] # Enable block API traits -mac = ["subtle"] # Enable MAC traits +mac = ["dep:ctutils"] # Enable MAC traits rand_core = ["common/rand_core"] # Enable random key generation methods getrandom = ["common/getrandom", "rand_core"] oid = ["const-oid"] diff --git a/digest/src/mac.rs b/digest/src/mac.rs index 03c24a00e..dc2905255 100644 --- a/digest/src/mac.rs +++ b/digest/src/mac.rs @@ -3,7 +3,7 @@ use common::{Output, OutputSizeUser, Reset}; use common::typenum::Unsigned; use core::fmt; -use subtle::ConstantTimeEq; +use ctutils::CtEq; /// Marker trait for Message Authentication algorithms. pub trait MacMarker {}