ssh tunnel through an intermediate host

Posted by user1190650 on Super User See other posts from Super User or by user1190650
Published on 2012-10-31T20:38:26Z Indexed on 2012/10/31 23:04 UTC
Read the original article Hit count: 143

Filed under:
|

I have configured an SSH tunnel to forward my web traffic from hostA to hostC using this command on hostA:

    ssh -D 2222 user@hostC

after configuring my browser to use a proxy on port 2222. This works great. However, I now want to forward the same traffic through an intermediate SSH connection on hostB in order to get to hostC.

I tried this on hostA:

    ssh user@hostB -L 2222:hostB:22

but I get "channel x: open failed" errors. Does anyone know the correct way of doing this?

© Super User or respective owner

Related posts about ssh

Related posts about tunnel