pub struct SocksV4<C> { /* private fields */ }
Expand description
Tunnel Proxy via SOCKSv4
This is a connector that can be used by the legacy::Client
. It wraps
another connector, and after getting an underlying connection, it established
a TCP tunnel over it using SOCKSv4.
Implementations§
Source§impl<C> SocksV4<C>
impl<C> SocksV4<C>
Sourcepub fn new(proxy_dst: Uri, connector: C) -> Self
pub fn new(proxy_dst: Uri, connector: C) -> Self
Create a new SOCKSv4 handshake service
Wraps an underlying connector and stores the address of a tunneling proxying server.
A SocksV4
can then be called with any destination. The dst
passed to
call
will not be used to create the underlying connection, but will
be used in a SOCKS handshake with the proxy destination.
Trait Implementations§
Source§impl<C> Service<Uri> for SocksV4<C>
impl<C> Service<Uri> for SocksV4<C>
Source§type Future = Handshaking<<C as Service<Uri>>::Future, <C as Service<Uri>>::Response, <C as Service<Uri>>::Error>
type Future = Handshaking<<C as Service<Uri>>::Future, <C as Service<Uri>>::Response, <C as Service<Uri>>::Error>
The future response value.
Auto Trait Implementations§
impl<C> !Freeze for SocksV4<C>
impl<C> RefUnwindSafe for SocksV4<C>where
C: RefUnwindSafe,
impl<C> Send for SocksV4<C>where
C: Send,
impl<C> Sync for SocksV4<C>where
C: Sync,
impl<C> Unpin for SocksV4<C>where
C: Unpin,
impl<C> UnwindSafe for SocksV4<C>where
C: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more