Rikard Johnels wrote:
Hi all!
I must be either totally blind or just plain stupid, but i cant find the way to scp and ssh thru a firewall.
Scenario 1: Workstation connecting to the outside of a firewall and then from the wall to a server on the inside network. Ok the stupid way is probably: ssh user@red-net.domian.com (loggin in) ssh another-user@green-server.inside.net
I know there must be a way to redirect the ssh session so i wont have to login twice (Did it with VNC a few years back, but cant seem to find the page that described how...)
Scenario 2. Same set up, but i need to copy a file from workstation to green-server via the firewall.
Can that be done via a allready set up ssh session (sort of like VPN) Can the scp command be redirected?
You have to set up port forwarding. If you still want to be able to connect to the firewall, you'll have to choose a second port number. This way, one port number talks to the firewall and the other is forwarded to a computer behind the firewall.