From: Mira Limbeck <m.limbeck@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: Re: [pve-devel] [PATCH proxmox-openid] fix #6541: openid: add missing connector chains
Date: Mon, 21 Jul 2025 16:50:03 +0200 [thread overview]
Message-ID: <c9034614-5988-4c19-9c49-6e9e20b9469c@proxmox.com> (raw)
In-Reply-To: <20250721144832.570040-1-m.limbeck@proxmox.com>
On 7/21/25 16:48, Mira Limbeck wrote:
> With the upgrade to ureq 3 the TLS connectors (native-tls, rustls) now
> require a transport (tcp) in the chain before it, otherwise they panic.
>
> For HTTP Connect proxy support another ConnectProxy connector is
> required.
> The new chain, based on the DefaultConnector [0] chain in ureq, needs to
> have the connectors in the order of:
> ConnectProxy -> Tcp -> Tls
>
> [0] https://github.com/algesten/ureq/blob/3.0.11/src/unversioned/transport/mod.rs#L346
>
> Signed-off-by: Mira Limbeck <m.limbeck@proxmox.com>
> ---
> proxmox-openid/src/http_client.rs | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
> mode change 100644 => 100755 proxmox-openid/src/http_client.rs
>
> diff --git a/proxmox-openid/src/http_client.rs b/proxmox-openid/src/http_client.rs
> old mode 100644
> new mode 100755
> index e4628170..7d383d5d
> --- a/proxmox-openid/src/http_client.rs
> +++ b/proxmox-openid/src/http_client.rs
> @@ -4,6 +4,7 @@ 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
> @@ -43,7 +44,9 @@ fn ureq_agent() -> Result<ureq::Agent, Error> {
> }
> let agent = ureq::Agent::with_parts(
> config.build(),
> - ureq::unversioned::transport::NativeTlsConnector::default(),
> + ureq::unversioned::transport::ConnectProxyConnector::default()
> + .chain(ureq::unversioned::transport::TcpConnector::default())
> + .chain(ureq::unversioned::transport::NativeTlsConnector::default()),
> ureq::unversioned::resolver::DefaultResolver::default(),
> );
>
Sorry, the `openid` in the subject is a bit redundant. This should have
been `http_client` or maybe omitted entirely.
_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
next prev parent reply other threads:[~2025-07-21 14:49 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-21 14:48 Mira Limbeck
2025-07-21 14:50 ` Mira Limbeck [this message]
2025-07-21 15:37 ` [pve-devel] applied: " Thomas Lamprecht
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=c9034614-5988-4c19-9c49-6e9e20b9469c@proxmox.com \
--to=m.limbeck@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