diff options
author | Nick Mathewson <nickm@torproject.org> | 2009-08-26 11:34:45 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2009-08-26 11:34:45 -0400 |
commit | c9203749a2ead39433fa4f62452a2360e0901e42 (patch) | |
tree | f0d6ff4b9b93f2726134a3033c023ebc0ec6ce8a /src/or | |
parent | 707a6bd6595024e0b4a998e0a99eb284499a37e3 (diff) | |
download | tor-c9203749a2ead39433fa4f62452a2360e0901e42.tar.gz tor-c9203749a2ead39433fa4f62452a2360e0901e42.zip |
A changelog entry and a bit more documentation for socks-client
Diffstat (limited to 'src/or')
-rw-r--r-- | src/or/config.c | 3 | ||||
-rw-r--r-- | src/or/or.h | 18 | ||||
-rw-r--r-- | src/or/reasons.c | 2 |
3 files changed, 14 insertions, 9 deletions
diff --git a/src/or/config.c b/src/or/config.c index c5a5b946fe..7944aa1001 100644 --- a/src/or/config.c +++ b/src/or/config.c @@ -3533,6 +3533,9 @@ options_validate(or_options_t *old_options, or_options_t *options, } } + if (options->Socks4Proxy && options->Socks5Proxy) + REJECT("You cannot specify both Socks4Proxy and SOCKS5Proxy"); + if (options->Socks5ProxyUsername) { size_t len; diff --git a/src/or/or.h b/src/or/or.h index df57f3048d..1aa40af61b 100644 --- a/src/or/or.h +++ b/src/or/or.h @@ -2392,15 +2392,15 @@ typedef struct { uint16_t HttpsProxyPort; /**< Parsed port for https proxy, if any. */ char *HttpsProxyAuthenticator; /**< username:password string, if any. */ - char *Socks4Proxy; - tor_addr_t Socks4ProxyAddr; - uint16_t Socks4ProxyPort; - - char *Socks5Proxy; - tor_addr_t Socks5ProxyAddr; - uint16_t Socks5ProxyPort; - char *Socks5ProxyUsername; - char *Socks5ProxyPassword; + char *Socks4Proxy; /**< hostname:port to use as a SOCKS4 proxy, if any. */ + tor_addr_t Socks4ProxyAddr; /**< Derived from Socks4Proxy. */ + uint16_t Socks4ProxyPort; /**< Derived from Socks4Proxy. */ + + char *Socks5Proxy; /**< hostname:port to use as a SOCKS5 proxy, if any. */ + tor_addr_t Socks5ProxyAddr; /**< Derived from Sock5Proxy. */ + uint16_t Socks5ProxyPort; /**< Derived from Socks5Proxy. */ + char *Socks5ProxyUsername; /**< Username for SOCKS5 authentication, if any */ + char *Socks5ProxyPassword; /**< Password for SOCKS5 authentication, if any */ /** List of configuration lines for replacement directory authorities. * If you just want to replace one class of authority at a time, diff --git a/src/or/reasons.c b/src/or/reasons.c index 78a16af10e..0544990679 100644 --- a/src/or/reasons.c +++ b/src/or/reasons.c @@ -326,6 +326,7 @@ circuit_end_reason_to_control_string(int reason) } } +/** Return a string corresponding to a SOCKS4 reponse code. */ const char * socks4_response_code_to_string(uint8_t code) { @@ -343,6 +344,7 @@ socks4_response_code_to_string(uint8_t code) } } +/** Return a string corresponding to a SOCKS5 reponse code. */ const char * socks5_response_code_to_string(uint8_t code) { |