From 50b59e04e5a7350b82d1f56430d1654cebcd6cf8 Mon Sep 17 00:00:00 2001 From: Paul Hansen Date: Sun, 15 Dec 2024 09:30:16 -0600 Subject: [PATCH] Allow https for user detail (#191) --- src/infra/userdetail_http.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/infra/userdetail_http.rs b/src/infra/userdetail_http.rs index c0f4e1f..a8e03d4 100644 --- a/src/infra/userdetail_http.rs +++ b/src/infra/userdetail_http.rs @@ -47,7 +47,13 @@ impl UserDetailProvider for HTTPUserDetailProvider { .body(Body::empty()) .map_err(|e| UserDetailError::with_source("error creating request", e))?; - let client = Client::new(); + let https = hyper_rustls::HttpsConnectorBuilder::new() + .with_native_roots() + .https_or_http() + .enable_http1() + .build(); + + let client = Client::builder().build(https); let resp = client .request(req)