[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ERC through a gateway

From: Daniel Pittman
Subject: Re: ERC through a gateway
Date: Thu, 29 Apr 2010 19:58:14 +1000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) (Paulo J. Matos) writes:
> Daniel Pittman <> writes:
>>>> (defun dp/erc-via-ssh-and-netcat (name buffer host port)
>>>>   "Establish a connection via ssh and netcat on the destination host"
>>>>   (let ((process-connection-type nil)
>>>>         (command (list "/usr/bin/ssh" host "nc" "-q" "1" host 
>>>> (int-to-string port))))
>>>>     (apply 'start-process name buffer command)))
>> This uses ssh to connect to a remote machine, then tunnels TCP/IP to a remote
>> system using netcat.
> So, you end up always needing a remote machine that you can ssh to that
> provides a way to do a direct tcp/ip connection, right?

Well, if you use my command as written you would.  OTOH, you can substitute
*any* command that connects STDIN/STDOUT to a remote TCP socket here, and it
will do the right thing.

So, if you need to tunnel through an HTTP CONNECT gateway get something that
connects that way, and replace the ssh call with that, and bob is your mothers
brother, as the saying goes.

Er, I have been assuming that y'all know how to look up the documentation for
the various customizable variables and so forth.  If not, there is a whole lot
of information about the API for this stuff hidden away there that you could
use to perhaps better understand what is happening.

For how to do that, if you don't know, see the "Documentation Lookup" section
of the info supplied with Emacs, or here:

✣ Daniel Pittman            ✉            ☎ +61 401 155 707
               ♽ made with 100 percent post-consumer electrons

reply via email to

[Prev in Thread] Current Thread [Next in Thread]