From d91ef469595da9fc0816f8c1efb2acf32c429996 Mon Sep 17 00:00:00 2001 From: Philipp Krones Date: Mon, 28 Oct 2024 17:02:56 +0100 Subject: [PATCH] Disable rustls' aws-lc-rs feature When both the `ring` and `aws-lr-rs` features in `rustls` are enabled, the rustls `CryptoProvider` installer from crate features no longer works, as the provider to be used is ambiguous [1]. This is the default configuration and feature set that other dependencies like `reqwest` are using. [1]: https://docs.rs/rustls/latest/src/rustls/crypto/mod.rs.html#261-282 --- Cargo.toml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index c24367e..9c36590 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -27,7 +27,9 @@ rand = { version = "0.8.5", optional = true } reqwest = { version = "0.12.2", optional = true, default-features = false, features = [ "json", ] } -rustls = { version = "0.23.4", optional = true } +rustls = { version = "0.23.4", optional = true, default-features = false, features = [ + "ring", +] } serde = { version = "1", features = ["derive"], optional = true } serde_json = { version = "1", optional = true } thiserror = { version = "2", optional = true } @@ -43,7 +45,7 @@ default = ["default-tls", "tokio", "ureq"] # These features are only relevant when used with the `tokio` feature, but this might change in the future. default-tls = [] native-tls = ["dep:reqwest", "reqwest/default", "dep:native-tls", "ureq/native-tls"] -rustls-tls = ["dep:rustls", "reqwest/rustls-tls"] +rustls-tls = ["dep:reqwest", "dep:rustls", "reqwest/rustls-tls"] tokio = [ "dep:futures", "dep:indicatif",