Networking Forums

Networking Forums > Computer Networking > Linux Networking > reverse SSH tunnel problem

Reply
Thread Tools Display Modes

reverse SSH tunnel problem

 
 
p cooper
Guest
Posts: n/a

 
      11-09-2005, 10:18 PM
Ive got a reverse tunnel from my work server ot my home server and then i
can get back to work
-------Work-------------- Home--------------------------------home client
Servername=test1 Name=grenada
IP address 10.138.0.10 internal 192.168.0.1 IP=192.168.0.12
running apache

I do

ssh -R 2096:localhost:80 www.myserver
and then go home

http://grenada:2096 from the home client brings up the default apache index
page on the work server

but I want to go to a directory that I access at work as
http://10.138.0.10/mediawiki

with the servername in apache set to test1
when I enter http://grenada:2096/mediawiki on the home client konqueror i
get "unknown host test1"

changing the servername to localhost its "Could not connect to host
localhost."

changing the DocumentRoot to /var/www/localhost/htdocs/mediawiki

-> test1 ( or locahost) not found

Ive added to test1:/etc/hosts
10.138.0.10 localhost
127.0.0.1 test1

and Ive added to grenada :/etc/hosts
127.0.0.1 test1

all to no avail.

Is there a way ?

 
Reply With Quote
 
 
 
 
Philippe WEILL
Guest
Posts: n/a

 
      11-10-2005, 10:47 AM


p cooper wrote:
> Ive got a reverse tunnel from my work server ot my home server and then i
> can get back to work
> -------Work-------------- Home--------------------------------home client
> Servername=test1 Name=grenada
> IP address 10.138.0.10 internal 192.168.0.1 IP=192.168.0.12
> running apache
>
> I do
>
> ssh -R 2096:localhost:80 www.myserver
> and then go home
>
> http://grenada:2096 from the home client brings up the default apache index
> page on the work server


If you use virtualhosting by name on your http server
ssh tunelling doesn't work to access virtual host

>
> but I want to go to a directory that I access at work as
> http://10.138.0.10/mediawiki
>
> with the servername in apache set to test1
> when I enter http://grenada:2096/mediawiki on the home client konqueror i
> get "unknown host test1"
>
> changing the servername to localhost its "Could not connect to host
> localhost."
>
> changing the DocumentRoot to /var/www/localhost/htdocs/mediawiki
>
> -> test1 ( or locahost) not found
>
> Ive added to test1:/etc/hosts
> 10.138.0.10 localhost
> 127.0.0.1 test1
>
> and Ive added to grenada :/etc/hosts
> 127.0.0.1 test1
>
> all to no avail.
>
> Is there a way ?
>

 
Reply With Quote
 
p cooper
Guest
Posts: n/a

 
      11-15-2005, 08:38 AM
its not a virtual host configuration

I can get to my apache default installation
once the tunnel is up

http://serverathome:2096 and I see http://serveratwork:80
the problem is that I cant get to

http://serveratwork:2096/mediawiki

I get a 'serveratwork not found 'apache error message

If I add to me desktop client /etc/hosts
serveratwork 192.168.0.1(serverathome IP address) I get a you must
configure your wiki error message , even though my secretary ( in the
office) can access it


 
Reply With Quote
 
David Efflandt
Guest
Posts: n/a

 
      11-21-2005, 06:55 AM
On Wed, 09 Nov 2005, p cooper <pdconetwofour_numbers_@yahoo.co.uk> wrote:
> Ive got a reverse tunnel from my work server ot my home server and then i
> can get back to work
> -------Work-------------- Home--------------------------------home client
> Servername=test1 Name=grenada
> IP address 10.138.0.10 internal 192.168.0.1 IP=192.168.0.12
> running apache
>
> I do
>
> ssh -R 2096:localhost:80 www.myserver
> and then go home
>
> http://grenada:2096 from the home client brings up the default apache index
> page on the work server
>
> but I want to go to a directory that I access at work as
> http://10.138.0.10/mediawiki
>
> with the servername in apache set to test1
> when I enter http://grenada:2096/mediawiki on the home client konqueror i
> get "unknown host test1"


I bet http://grenada:2096/mediawiki/ would work. A trailing slash is
required when no filename is specified, and apache is trying to fix it by
redirecting you there. See apache docs for UseCanonicalName (setting that
off may help if you are prone to using incomplete URLs).
 
Reply With Quote
 
JosephKK
Guest
Posts: n/a

 
      11-30-2005, 05:06 AM
p cooper wrote:

> its not a virtual host configuration
>
> I can get to my apache default installation
> once the tunnel is up
>
> http://serverathome:2096 and I see http://serveratwork:80
> the problem is that I cant get to
>
> http://serveratwork:2096/mediawiki
>
> I get a 'serveratwork not found 'apache error message
>
> If I add to me desktop client /etc/hosts
> serveratwork 192.168.0.1(serverathome IP address) I get a you must
> configure your wiki error message , even though my secretary ( in the
> office) can access it
>
>

You have hidden NAT in both directions. you are lucky to get it to work at
all. HTTP is very tolerant about finding hosts with arp and rarp. SSH
requires that you understand the NAT both ways.
--
JosephKK

 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
IPSEC tunnel problem Sandro Linux Networking 2 03-19-2008 11:33 AM
Site to site tunnel file sharing problem Robert Jacobs Windows Networking 5 05-30-2007 06:49 PM
btexact tunnel not doing assigning reverse delegation for my ipv6address Asfand Yar Qazi Home Networking 0 02-20-2007 10:32 PM
reverse lookup IP problem?? cmk128@hotmail.com Linux Networking 4 10-16-2006 12:58 AM
Reverse ip lookup problem? Retlak Linux Networking 8 10-13-2004 07:59 PM



1 2 3 4 5 6 7 8 9 10 11