-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

Jas
  • 701
  • 4
  • 13
  • 23

1 Answers1

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.

skazi
  • 196
  • 1
  • 3