pub enum Socks5ConnectError {
UnexpectedVersion(u8),
NoAcceptableAuthMethod,
UnsupportedAuthMethod(u8),
AuthRequired,
UnexpectedAuthVersion(u8),
AuthRejected,
Reply(Socks5Reply),
UnknownReply(u8),
UnknownAddressType(u8),
Malformed,
}socks5 only.Expand description
Failure causes during the SOCKS5 CONNECT handshake.
Variants§
UnexpectedVersion(u8)
The proxy replied with a SOCKS version other than 0x05.
NoAcceptableAuthMethod
The proxy accepted none of the offered authentication methods.
UnsupportedAuthMethod(u8)
The proxy selected an authentication method the client did not offer or does not support.
AuthRequired
The proxy asked for username/password auth but no credentials were configured.
UnexpectedAuthVersion(u8)
The auth sub-negotiation carried a version other than 0x01.
AuthRejected
The proxy rejected the username/password credentials.
Reply(Socks5Reply)
The proxy refused the CONNECT with a known reply code.
UnknownReply(u8)
The proxy replied with a reply code outside the RFC 1928 range.
UnknownAddressType(u8)
The proxy reply used an address type the client cannot parse.
Malformed
A message from the proxy was shorter than its fixed framing requires (a misbehaving pump or proxy).
Trait Implementations§
Source§impl Clone for Socks5ConnectError
impl Clone for Socks5ConnectError
Source§fn clone(&self) -> Socks5ConnectError
fn clone(&self) -> Socks5ConnectError
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for Socks5ConnectError
impl Debug for Socks5ConnectError
Source§impl Display for Socks5ConnectError
impl Display for Socks5ConnectError
impl Eq for Socks5ConnectError
Source§impl Error for Socks5ConnectError
impl Error for Socks5ConnectError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl From<Socks5ConnectError> for ProxyClientError
Available on crate feature client and (crate features http or socks5) only.
impl From<Socks5ConnectError> for ProxyClientError
client and (crate features http or socks5) only.