mirror of
https://github.com/servo/servo.git
synced 2025-08-31 18:18:21 +01:00
Add command-line argument to use a custom SSL certificate database.
This commit is contained in:
parent
d7fb2cc27f
commit
dc99104f55
7 changed files with 36 additions and 13 deletions
|
@ -530,7 +530,8 @@ fn test_fetch_with_hsts() {
|
|||
//takes an address and something that implements hyper::net::Ssl
|
||||
let mut server = Server::https("0.0.0.0:0", ssl).unwrap().handle_threads(handler, 1).unwrap();
|
||||
|
||||
let ssl_client = create_ssl_client("self_signed_certificate_for_testing.crt");
|
||||
let ca_file = resources_dir_path().unwrap().join("self_signed_certificate_for_testing.crt");
|
||||
let ssl_client = create_ssl_client(&ca_file);
|
||||
let connector = create_http_connector(ssl_client);
|
||||
|
||||
let context = FetchContext {
|
||||
|
|
|
@ -42,6 +42,7 @@ use net::test::HttpState;
|
|||
use net_traits::FetchTaskTarget;
|
||||
use net_traits::request::Request;
|
||||
use net_traits::response::Response;
|
||||
use servo_config::resource_files::resources_dir_path;
|
||||
use servo_url::ServoUrl;
|
||||
use std::sync::Arc;
|
||||
use std::sync::mpsc::{Sender, channel};
|
||||
|
@ -53,7 +54,8 @@ struct FetchResponseCollector {
|
|||
}
|
||||
|
||||
fn new_fetch_context(dc: Option<Sender<DevtoolsControlMsg>>) -> FetchContext {
|
||||
let ssl_client = create_ssl_client("certs");
|
||||
let ca_file = resources_dir_path().unwrap().join("certs");
|
||||
let ssl_client = create_ssl_client(&ca_file);
|
||||
let connector = create_http_connector(ssl_client);
|
||||
FetchContext {
|
||||
state: Arc::new(HttpState::new()),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue