-3

I have my localhost, gateway, remote web server. I cannot access remote web server from localhost.

Is there an ssh tunneling command which I can run only on my localhost which would provide me access to the remote web server on port 8080? anything like

ssh -L 8080:gateway:*

(what I wish for every request going to localhost 8080 make it as if the request was made on gateway and return the result to me, all this without opening a new port in addition to 22 on the remote gateway).

thanks

1
  • 1
    Have you tried ssh gateway -L 8080:remote-web-server:8080?
    – MadHatter
    Feb 28, 2016 at 9:52

1 Answer 1

1

If you have ssh access to your gateway, following command should do what you describe:

ssh gateway -L 8080:webserver:8080 -N

This will ask you for gateway password and "hang" until you kill it with Ctrl+C.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .