0

Currently I have the following problem: I can connect to Server B via ssh only if I connect to Server A (via ssh), create socks proxy with putty, and use it in order to connect to server B.

So connection is MyPC -> Server A -> Server B. What I need is to be able to call from Server B localhost:xx and forward it to MyPc:xx

With single tunnel it can be done via Putty by simply adding rule R7869 localhost:7869 (and it's working for Server A which connection is being made directly), however if I'm trying to do the same on Server B (which is proxyfied) it's not working.

Any ideas?

EDIT: I have found solution to this problem. Instead of creating new network connection with putty to server B, I need to call ssh -R 7869:localhost:7869 root@ServerB from Server A.

Gryu
  • 479
  • 1
  • 6
  • 14
Alekc
  • 125
  • 1
  • 2
  • 6
  • There is a good solution here http://serverfault.com/questions/340865/ssh-tunnel-over-multi-hops-using-putty – Scott Jan 03 '13 at 22:33

1 Answers1

3

"What i need is to be able to call from server B localhost:xx and forward it to MyPc:xx"

First session to server_A: a.example.com:22

 L22000 b.example.com:22

Second session to server_B (via tunnel from first session): localhost:22000

 L8080 localhost:8080

The end effect is MyPC:8080 <-> b.example.com:8080

Casual Coder
  • 1,216
  • 1
  • 11
  • 12