Skip to content

Commit

Permalink
Merge pull request #36 from valorem-labs-inc/cloudflare_ssl
Browse files Browse the repository at this point in the history
Use a valid root CA from operating system and valid fqdn in example
  • Loading branch information
0xAlcibiades authored Apr 12, 2023
2 parents 516245a + 79a462a commit 8032386
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions examples/client/market_maker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,12 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
}

// TLS Configuration
let data_dir = std::path::PathBuf::from_iter([std::env!("CARGO_MANIFEST_DIR"), "certs"]);
let pem = std::fs::read_to_string(data_dir.join("rootCA.crt")).unwrap();
let pem = std::fs::read_to_string("/etc/ssl/cert.pem").unwrap();
let ca = Certificate::from_pem(pem);

let tls_config = ClientTlsConfig::new()
.ca_certificate(ca)
.domain_name("localhost.com");
.domain_name("exchange.valorem.xyz");

let quay_uri = args[0].parse::<Uri>().unwrap();
let (session_cookie, maker_address) =
Expand Down

0 comments on commit 8032386

Please sign in to comment.