incoming request and sends it to another // server, proxying the response back to the client. type ReverseProxy struct { // Rewrite must be a function which modifies // the request into a new request to be sent // using Transport. Its response is then copied // back to the original client unmodified. // … Rewrite func(*ProxyRequest)
host for the Host header provided to the remote host (not the Host header submitted to the proxy) > Fix: The outbound request from the proxy has two [Hh]ost headers. Update proxy to treat headers case-insensitively.
= listener.accept().await?; let acceptor = tls_acceptor.clone(); let context = context.clone(); tokio::spawn(async move { match acceptor.accept(stream).await { Ok(tls_stream) => { // Wrap the TLS stream with TokioIo for Hyper compatibility let io = TokioIo::new(tls_stream);