connect-proxy - Man Page

connect over SOCKS4/5 proxy


connect-proxy [-dnhst45]  [-R resolve ]  [-p local-port ]  [-w secs ]  [-H [user@]proxy-server[:port]] ]  [-S [user@]socks-server[:port]] ]  [-T proxy-server[:port] ]  [-c telnet-proxy-command ]  [host]  [port]  


connect-proxy open connection over SOCKS4/5 proxies

Please, note that any HTTP-Proxy tunnel won't work with content-inspection firewall (unless using SSL).



specifies a hostname and port number of the http proxy   server to relay. If port is omitted, 80 is used. You can specify this  value in the environment variable HTTP_PROXY and pass the -h option  to use it.


specifies the hostname and port number of the SOCKS  server to relay.  Like -H, port number can be omitted and the default  is 1080. You can also specify this value pair in the environment  variable SOCKS5_SERVER and give the -s option to use it.


specifies SOCKS relaying and indicates protocol version to use.   It is valid only when used with '-s' or '-S'.   Default is '-5' (protocol version 5)


method to resolve the  hostname. Three keywords ("local", "remote", "both") or dot-notation  IP address are acceptable.  The keyword "both" means, "Try local  first, then remote". If a dot-notation IP address is specified, use  this host as nameserver. The default is "remote" for SOCKS5 or  "local" for others. On SOCKS4 protocol, remote resolving method  ("remote" and "both") requires protocol 4a supported server.


will forward a local TCP port instead of using the  standard input and output.


same to '-p' except keep remote session. The  program repeats waiting the port with holding remote session without  disconnecting. To connect the remote session, send EOF to stdin or  kill the program.


timeout in seconds for making connection with TARGET host.


used for debug. If you fail to connect, use this and check request to and response from server.


To use proxy, this example is for SOCKS5 connection to connect to
 connect-proxy -S firewall host 25  
 SOCKS5_SERVER=firewall; export SOCKS5_SERVER;   connect-proxy -s host 25

For a HTTP-PROXY connection:
 connect-proxy -H proxy-server:8080  host 25  
 HTTP_PROXY=proxy-server:8080; export HTTP_PROXY;   connect-proxy -h host 25  

To forward a local port, for example to use ssh:
 connect-proxy -H proxy-server:8080  host 22   ssh -l user -p 5550 localhost

To use it along ssh transparently:   # file://~/.ssh/config  Host *  ProxyCommand connect-proxy -H proxy-server:8080  %h %p



See Also

ssh (1).



This manual page was written by Philippe COVAL for  the Debian system (but may be used by others).  Permission is  granted to copy, distribute and/or modify this document under  the terms of the GNU General Public License, Version 2 any   later version published by the Free Software Foundation.

On Debian systems, the complete text of the GNU General Public  License can be found in /usr/share/common-licenses/GPL.