Crate hyper_socks2

source ·
Expand description

The reborn of the SOCKS4/5 connector for Hyper library

Example

use hyper::{client::Client, Body};
use hyper_socks2::{Connector, Proxy};

let proxy = Proxy::Socks5 {
    addrs: "your.socks5.proxy:1080",
    auth: None,
};

// HTTP
let connector = Connector::new(proxy);
// or HTTPS
let connector = Connector::with_tls(proxy)?;

let client = Client::builder().build::<_, Body>(connector);

Structs

An authentication information
A future with ready TCP stream
A TCP connector working through proxy
An error returned from the TLS implementation.
A Connector for the https scheme.

Enums

A SOCKS4/5 proxy information