Struct socks::Socks5Listener [] [src]

pub struct Socks5Listener(_);

A SOCKS5 BIND client.

Methods

impl Socks5Listener
[src]

fn bind<T, U>(proxy: T, target: U) -> Result<Socks5Listener> where T: ToSocketAddrs, U: ToTargetAddr

Initiates a BIND request to the specified proxy.

The proxy will filter incoming connections based on the value of target.

fn proxy_addr(&self) -> SocketAddr

The address of the proxy-side TCP listener.

This should be forwarded to the remote process, which should open a connection to it.

fn accept(self) -> Result<Socks5Stream>

Waits for the remote process to connect to the proxy server.

The value of proxy_addr should be forwarded to the remote process before this method is called.

Trait Implementations

impl Debug for Socks5Listener
[src]

fn fmt(&self, __arg_0: &mut Formatter) -> Result

Formats the value using the given formatter.