deltachat::net::proxy

Function http_tunnel

source
async fn http_tunnel<T>(
    conn: T,
    host: &str,
    port: u16,
    auth: Option<(&str, &str)>,
) -> Result<T>
where T: AsyncReadExt + AsyncWriteExt + Unpin,
Expand description

Sends HTTP/1.1 CONNECT request over given connection to establish an HTTP tunnel.

Returns the same connection back so actual data can be tunneled over it.