public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Thomas Lamprecht <t.lamprecht@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] applied: [PATCH 2/2] openid connect: http client: avoid unversioned ureq module
Date: Mon, 21 Jul 2025 18:52:33 +0200	[thread overview]
Message-ID: <20250721165306.64972-2-t.lamprecht@proxmox.com> (raw)
In-Reply-To: <20250721165306.64972-1-t.lamprecht@proxmox.com>

It's simply not needed so do not bother with it.

Brings us again closer to what the proxmox-http sync client does, now
at least it's again so simple that there can be an argument for doing
this ourselves here over pulling in more dependencies.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
---
 proxmox-openid/src/http_client.rs | 11 +----------
 1 file changed, 1 insertion(+), 10 deletions(-)

diff --git a/proxmox-openid/src/http_client.rs b/proxmox-openid/src/http_client.rs
index 904a5bac..a21e1d5a 100755
--- a/proxmox-openid/src/http_client.rs
+++ b/proxmox-openid/src/http_client.rs
@@ -4,7 +4,6 @@ use std::io::Read;
 use http::method::Method;
 
 use openidconnect::{HttpRequest, HttpResponse};
-use ureq::unversioned::transport::Connector;
 
 // Copied from OAuth2 create, because we want to use ureq with
 // native-tls. But current OAuth2 crate pulls in rustls, so we cannot
@@ -47,15 +46,7 @@ fn ureq_agent() -> Result<ureq::Agent, Error> {
         let proxy = ureq::Proxy::new(&val).map_err(Box::new)?;
         config = config.proxy(Some(proxy));
     }
-    let agent = ureq::Agent::with_parts(
-        config.build(),
-        ureq::unversioned::transport::ConnectProxyConnector::default()
-            .chain(ureq::unversioned::transport::TcpConnector::default())
-            .chain(ureq::unversioned::transport::NativeTlsConnector::default()),
-        ureq::unversioned::resolver::DefaultResolver::default(),
-    );
-
-    Ok(agent)
+    Ok(config.build().into())
 }
 
 fn add_headers<T>(
-- 
2.47.2



_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel


      reply	other threads:[~2025-07-21 16:52 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-21 16:52 [pve-devel] applied: [PATCH 1/2] openid connect: http client: use TlS platform verifier Thomas Lamprecht
2025-07-21 16:52 ` Thomas Lamprecht [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250721165306.64972-2-t.lamprecht@proxmox.com \
    --to=t.lamprecht@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal