Skip to main content

connect_socks5

Function connect_socks5 

Source
pub fn connect_socks5<S: Read + Write>(
    stream: &mut S,
    target: Socks5Address,
    credentials: Option<Socks5Credentials>,
) -> Result<(), ProxyClientError>
Available on crate feature socks5 only.
Expand description

Runs the SOCKS5 CONNECT handshake on stream (already connected to the proxy), tunnelling to target and authenticating with credentials if the proxy asks for username/password.