Hi, I use putty in my windows xp machine. ssh server in a centos 4. The centos 4 machine runs a web server that listens on port 1812, the centos machine is behind a firewall that allows tcp 22 connections only. I am on public internet. Can I forward/redirect/allow my web browser in windows to "see" the web page in port 1812 of the centos machine via the SSH connection? Thanks, -- ------------------------------------------- Erick Perez Linux User 376588 http://counter.li.org/ (Get counted!!!) Panama, Republic of Panama
On Sun, 2005-11-06 at 13:06 -0500, Erick Perez wrote:> Hi, I use putty in my windows xp machine. ssh server in a centos 4. > The centos 4 machine runs a web server that listens on port 1812, the > centos machine is behind a firewall that allows tcp 22 connections > only. I am on public internet. > > Can I forward/redirect/allow my web browser in windows to "see" the > web page in port 1812 of the centos machine via the SSH connection? >I don't think you can use port 22 for ssh ... AND ... also forward it to port 1812. You could forward connections from one port of a firewall to a different port inside, if you want to do that. You could use freenx/nx server on the CentOS-4 machine (and use the NoMachine Windows Client) ... connect to it via ssh ... and open a desktop on the centos-4 machine. Then from that desktop, you could do whatever you wanted. -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part URL: <http://lists.centos.org/pipermail/centos/attachments/20051106/9b6fc115/attachment.sig>
On Sun, 2005-11-06 at 12:41, Johnny Hughes wrote:> On Sun, 2005-11-06 at 13:06 -0500, Erick Perez wrote: > > Hi, I use putty in my windows xp machine. ssh server in a centos 4. > > The centos 4 machine runs a web server that listens on port 1812, the > > centos machine is behind a firewall that allows tcp 22 connections > > only. I am on public internet. > > > > Can I forward/redirect/allow my web browser in windows to "see" the > > web page in port 1812 of the centos machine via the SSH connection? > > > > I don't think you can use port 22 for ssh ... AND ... also forward it to > port 1812.Putty or ssh can portforward local ports through the ssh connection to anything on the other side of the connection. If you: ssh -L1812:localhost1812 your_ssh_server then point your browser at localhost:1812 the connection will actually go to the remote system's idea of localhost. Note that all the links on a web site have to be written as relative references for this to work beyond the first page (as they should anyway...). With putty you would set this up in the 'tunnel' dialog. The port numbers are arbitrary - there is no reason other than your sanity to make them the same at both ends. The remote address can also be some other machine that the remote side can reach, and you have the option of exposing the local port to other machines if you want (the default is local access only). If you are a system administrator and don't understand this, your internal services may be a lot less secure than you think. If you allow ssh logins you basically allow remote pass-through to other systems for anything the user could reach himself when logged in. -- Les Mikesell lesmikesell at gmail.com
On 11/6/05, Erick Perez <eaperezh at gmail.com> wrote:> Hi, I use putty in my windows xp machine. ssh server in a centos 4. > The centos 4 machine runs a web server that listens on port 1812, the > centos machine is behind a firewall that allows tcp 22 connections > only. I am on public internet. > > Can I forward/redirect/allow my web browser in windows to "see" the > web page in port 1812 of the centos machine via the SSH connection? >Use use ssh -D to create a tunneled socks proxy. set up a dynamic proxy in putty on port 3333 (can be anything over 1024 really ) then instruct your browser to use a socks proxy on localhost 3333. Most browsers try to prevent tunneling localhost traffic for websites, so you'll have to make sure that's not enabled. then point your browser to locahost:1812 and it'll work just fine.> Thanks, > > -- > > ------------------------------------------- > Erick Perez > Linux User 376588 > http://counter.li.org/ (Get counted!!!) > Panama, Republic of Panama > _______________________________________________ > CentOS mailing list > CentOS at centos.org > http://lists.centos.org/mailman/listinfo/centos >-- Jim Perrin System Administrator - UIT Ft Gordon & US Army Signal Center
Erick Perez wrote:>Hi, I use putty in my windows xp machine. ssh server in a centos 4. >The centos 4 machine runs a web server that listens on port 1812, the >centos machine is behind a firewall that allows tcp 22 connections >only. I am on public internet. > >Can I forward/redirect/allow my web browser in windows to "see" the >web page in port 1812 of the centos machine via the SSH connection? > >Thanks, > >-- > >------------------------------------------- >Erick Perez >Linux User 376588 >http://counter.li.org/ (Get counted!!!) >Panama, Republic of Panama >_______________________________________________ >CentOS mailing list >CentOS at centos.org >http://lists.centos.org/mailman/listinfo/centos > > >This is easy, and you don't have to do a thing on your server. Go here: http://www.benjamin.weiss.name:8000/putty-tunnel.html I use it to connect to my VNC server that runs locally, but you can use it to tunnel any port. Ben