# Can I forward http requests through a machine?

## bobwhoops

I'm home right now. At my college, we have access to this database that you can access through a browser with javascript, but you need to be on campus to get it.

I have ssh access to a machine on campus, but just a user account. It's not running X. Can I forward my http requests through that machine? How?

Or is my best option to locally install a text browser with javascript support in my home dir on that machine?

----------

## msalerno

You can use SSH to forward port 80 to the remote system.  Then you connect to localhost:80 from your web browser.

A quick google search on "SSH port forwarding" will return countless examples and howto's.

Check out the man page of ssh, or this link:

http://www.ovro.caltech.edu/~abeard/howto/ssh_port_forwarding.txt

----------

## bobwhoops

Ok, so I did

```
sudo ssh -l user -L 80:server:9000 server
```

and logged in. Then, in Firefox, I set the SOCKS host to use 127.0.0.1 on port 9000, but it's not working. Am I doing something wrong?

Edit: Setting Firefox to 127.0.0.1 on port 80 didn't work either

----------

## msalerno

So is there a proxy in this configuration?  Where did this SOCKS host come from?

Ok, here is the situation:

External client (EC) connects to internal client (IC) via ssh.

In that connection you create an ssh tunnel to internal webserver (IW)

should be something like this:

ssh -l user -L 80:IW:80 IC

Then connect to localhost:80 and you will have a tunnel to IW.

----------

