Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I am trying to connect from Vista to XP using RDP via reverse proxy using putty and an intermidiate host. There are myriad articles on the internet how to do it using vnc, ssh servers, winsshd, etc, but I can't find anything that helps me in this specific case.

What I have:

  1. Windows XP host behind the firewall - 'destination'
  2. linux host running ssh on the internet - 'intermediate'
  3. windows host behind the firewall - 'source'

All I want to do is open reverse tunnel from destination to intermidiate and use this tunnel for connecting back from the source. That should be simple to setup, however I just cannot make it.

This is what I do:

  • On 'destination', open putty session, create tunnel to 'intermediate' using following settings:
    source port 3389, destination is 'source:33389', direction is local

  • On 'source', open putty session, create tunnel to 'intermediate'using following settings:
    source port 33389, destination is 'destination:33389', direction is local

  • Finally, on source, open termnal services client and connect it to localhost:33389.Unfortunately it seems like packets do go somewhere but eventually client times out.

Am I totally misunderstanding the concept?
Please help!

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

It sounds like you should be close, but here is the setup you should have:

  • On destination, open PuTTY session and create a tunnel to intermediate using the following settings
    • Source port: 33898
    • Destination: localhost:3389
    • Remote

Explanation:
Since the connection is originating from source, and you want to listen on a port on intermediate to be forwarded to source, the tunnel must be remote. So a socket will be opened on port 33389 on intermediate which will be output on the local machine(destination) to localhost:3389, where the RDP server is listening.

Technically that is all you should need. As long as your source computer can see intermediate and intermediate will accept connections from the internet on port 33389, you should be able to point your RDP client to intermediate:33389 and be done with it.

Update: In order to have just the single tunnel you do need to select the Remote ports do the same checkbox, and as the PuTTY manual states, this feature may be disabled on the server.

However, if you do want to tunnel your connection from source to intermediate as well, here is the second part of the conifg:

  • On source, open a PuTTY session and create a tunnel to intermediate using the following settings:
    • Source port: 3389
    • Destination: localhost:33389
    • Local
    • Point the RDP client on source to localhost and it should connect.
share|improve this answer
    
Thanksa lot! Some clarifications: Did you mean Source port 33389? "will accept connections from the internet on port 3389" - I need to intermediate on arbitrary host , hence 33389. –  Sergei Mar 5 '10 at 21:56
    
Thank you, I think I grasp the concept now. There is also setting in Putty "Local ports accept connections from other hosts" -should not it be enabled? –  Sergei Mar 5 '10 at 22:15
    
I think I fixed any discrepancies in the port numbers. And see my updated for the second question. –  heavyd Mar 6 '10 at 23:57
    
Thank you very much for your help!All works now! –  Sergei Mar 8 '10 at 13:21
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.