You are not logged in.

#1 2004-07-09 17:23:26

kleptophobiac
Member
From: Sunnyvale, CA
Registered: 2004-04-25
Posts: 481

Having trouble with reverse SSH tunnels

I'm using the command:

ssh -fNC -l $USER -i /home/$USER/.ssh/id_rsa -R 1234:localhost:22 $HOST

This sets up a tunnel back to my house in order to bypass a draconian firewall to allow me to ssh back into my server. Well, everything connects just fine, but when I try to ssh into the remote on port 1234, it pauses, and then comes back with connection refused.

The exact same script works just fine on my slackware box... yes, I removed the line from hosts.deny... I just can't figure it out.

Offline

#2 2004-07-09 19:55:14

kleptophobiac
Member
From: Sunnyvale, CA
Registered: 2004-04-25
Posts: 481

Re: Having trouble with reverse SSH tunnels

Funny, it works some times.... but not others. Seemingly random....

Offline

#3 2004-07-10 00:17:43

Xentac
Forum Fellow
From: Victoria, BC
Registered: 2003-01-17
Posts: 1,797
Website

Re: Having trouble with reverse SSH tunnels

It might be your draconian firewall that's killing the idle connection.  But that doesn't seem right if it worked just fine in slackware...


I have discovered that all of mans unhappiness derives from only one source, not being able to sit quietly in a room
- Blaise Pascal

Offline

#4 2004-07-10 02:00:14

kleptophobiac
Member
From: Sunnyvale, CA
Registered: 2004-04-25
Posts: 481

Re: Having trouble with reverse SSH tunnels

the script was a cron job with an if statement to check to see if it was running. It runs every ten minutes in cron. I wrote an echo into the file so I could log its actions, and it is indeed running on schedule, and establishes a connection when it needs to. Funny that it only sometimes gives me the connection refused error even when I check on the remote machine that the connection is there.  roll  It just doesn't make any sense.

I don't know what the big difference between slack and arch would be to cause that problem. sad

Offline

Board footer

Powered by FluxBB