Use aws-lc-rs as rust-tls provider (#35106)

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
This commit is contained in:
Jonathan Schwender 2025-01-30 20:10:49 +01:00 committed by GitHub
parent 534e78db53
commit 764feada30
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
11 changed files with 124 additions and 26 deletions

View file

@ -78,7 +78,7 @@ flate2 = "1"
futures = { version = "0.3", features = ["compat"] }
hyper = { workspace = true, features = ["full"] }
hyper-util = { workspace = true, features = ["server-graceful"] }
rustls = { workspace = true, features = ["ring"] }
rustls = { workspace = true }
[[test]]
name = "main"

View file

@ -149,7 +149,7 @@ fn receive_credential_prompt_msgs(
}
fn create_http_state(fc: Option<EmbedderProxy>) -> HttpState {
let _ = rustls::crypto::ring::default_provider().install_default();
let _ = rustls::crypto::aws_lc_rs::default_provider().install_default();
let override_manager = net::connector::CertificateErrorOverrideManager::new();
HttpState {

View file

@ -93,7 +93,7 @@ profile_traits = { workspace = true }
range = { path = "../range" }
ref_filter_map = "1.0.1"
regex = { workspace = true }
ring = { workspace = true }
aws-lc-rs = { workspace = true }
script_bindings = { path = "../script_bindings" }
script_layout_interface = { workspace = true }
script_traits = { workspace = true }

View file

@ -12,6 +12,7 @@ use aes::cipher::{BlockDecryptMut, BlockEncryptMut, KeyIvInit, StreamCipher};
use aes::{Aes128, Aes192, Aes256};
use aes_gcm::{AeadInPlace, AesGcm, KeyInit};
use aes_kw::{KekAes128, KekAes192, KekAes256};
use aws_lc_rs::{digest, hkdf, hmac, pbkdf2};
use base64::prelude::*;
use cipher::consts::{U12, U16, U32};
use dom_struct::dom_struct;
@ -20,7 +21,6 @@ use js::jsapi::{JSObject, JS_NewObject};
use js::jsval::ObjectValue;
use js::rust::MutableHandleObject;
use js::typedarray::ArrayBufferU8;
use ring::{digest, hkdf, hmac, pbkdf2};
use servo_rand::{RngCore, ServoRng};
use crate::dom::bindings::buffer_source::create_buffer_source;

View file

@ -109,6 +109,6 @@ gaol = "0.2.1"
[dev-dependencies]
libservo = { path = ".", features = ["tracing"] }
rustls = { version = "0.23", default-features = false, features = ["ring"] }
rustls = { version = "0.23", default-features = false, features = ["aws-lc-rs"] }
tracing = { workspace = true }
winit = "0.30.8"

View file

@ -25,7 +25,7 @@ use winit::raw_window_handle::{HasDisplayHandle, HasWindowHandle};
use winit::window::Window;
fn main() -> Result<(), Box<dyn Error>> {
rustls::crypto::ring::default_provider()
rustls::crypto::aws_lc_rs::default_provider()
.install_default()
.expect("Failed to install crypto provider");