Need help installing SSH tunnel

From: Andre Hinrichs (hinrichs_at_mpia.de)
Date: 07/26/03


Date: Fri, 25 Jul 2003 16:54:22 -0700

Hi all!

Unfortunately, I've spent nearly a week of testing without any success.
I've read a lot of web sites related to SSH tunneling, but nothing really
helped.
Here is the problem:

First of all, let me say that a SSH connection to the remote machine is
fully functional, means the SSH server is up.
Second, I can do a telnet from the remote machine to the mail daemon on the
same machine means the mail daemon is up also.
Third, when I try to build a SSH tunnel, everything looks fine until I try
to telnet from the local machine over the SSH tunnel to the remote mail
daemon.
The command I used installing the tunnel is:

ssh -v remote.machine.com -L 25110:localhost:110 -L 25025:localhost:25 -4

Means I want to have a tunnel for SMTP and POP3. The ports on the local
machine are 25110 and 25025 which is OK. The command succeeds. I have a
shell on the remote machine and the debug mode says that the tunnel has
been successfully installed:

debug1: Connections to local port 25025 forwarded to remote address
localhost:25

But when I try to connect I get a "Connection refused" error:

Local machine:

>telnet localhost 25025
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
Connection closed by foreign host.

Remote machine (the tunnel connection):

channel 3: open failed: connect failed: Connection refused
debug1: channel_free: channel 3: direct-tcpip: listening port 25025 for
localhost port 25, connect from 127.0.0.1 port 1220, nchannels 4

What am I doing wrong? Do I need to configure something special?
Let me say, that I've already added 'AllowTcpForwarding yes' and
'GatewayPorts yes' to /etc/ssh/sshd_config

Any help is highly welcome, since I really need this connection.

Thanx to all
Andre



Relevant Pages

  • Fwd: mysql connection through ssl tunnel
    ... can make mysql connections through the tunnel with no problems. ... If autossh watches over my ssh tunnel, who or what watches over autossh? ... I'm trying to grasp the connection between virtual terminals and this SSH tunnel... ...
    (freebsd-questions)
  • Tunneling application X app over ssh from client to server
    ... to indirectly using two ssh tunnels that I haven't managed to tunnel X ... I can however at that point open a direct connection from the remote ... I want to open an X application on the remote machine which will show up ...
    (Debian-User)
  • SSH Tunneling - How?
    ... Just need to setup one ssh tunnel from a remote port 80to ... Connecting to the remote machine as ROOT: ... Now, after this connection all stops, what seems all OK. ...
    (comp.os.linux.networking)
  • Re: Secret Underground.
    ... There is no intentional connection* from the GWR running tunnel into ... the quarries. ... connection, which is one reason why the quarry surveys are so accurate... ... The easternmost shaft is at a point where the tunnel roof is close to ...
    (uk.rec.subterranea)
  • Re: Secret Underground.
    ... There is no intentional connection* from the GWR running tunnel into ... connection, which is one reason why the quarry surveys are so accurate... ... The easternmost shaft is at a point where the tunnel roof is close to the level of the workings, so that one's unlikely but not impossible. ... There wouldn't be any need either: when the munitions store was planned and in use, exit through any of the western quarries was easily possible. ...
    (uk.rec.subterranea)

Loading