how to define a tunnel connection to remote desktop in putty?
Asked Answered
B

1

7

I need to connect (in rdp ) to a machine (let's call it #1) in my college network ( I have the internal IP of it ) , I also have access the to Linux server machine in the same network in ssh , that I can use to access the #1 , I'm using putty, can someone please explain to me how I can connect to it ?

[My laptop] --->[Linux server] --->[windows machine] in rdp

Thank you,

Bleeding answered 21/1, 2013 at 22:51 Comment(0)
S
13

Let's assume the following:

Linux Server - gate.college-server.com:22 (SSH listens on port 22)

Internal Server - internal.college-server.com:3389 (RDP listens on port 3389)

RDP connection will be on localhost:3399 (the port should be opened)

How to configure the SSH tunnel via Putty with RDP forwarding:

  • Open Putty and in the Session enter the connection info for the Linux Server
  • Go to branch > Connection > SSH > Tunnels
  • Choose Local and Auto
  • in the Source Port enter 3399, and in the Destination - the connection info of the internal machine in the format: hostname:port.
  • Click Add

you will see entry in the Forwarded ports section, something like:

4L3399   internal.college-server.com:3389

Save your connection and it's ready to use.

Next, start the a PuTTy Session with the Saved Connection and after you login successfully to the remote server gate.college-server.com:22, you can start your Windows RDP client.

Connect with it to localhost:3399 and use the RDP credentials for internal.college-server.com:3389

Subduct answered 2/2, 2013 at 16:36 Comment(5)
in rdp client in windows, are sure I have to enter: localhost:3399 ? it gives me an error "This computer can't connect to the remote computer"Bleeding
and the forward ports look like this: L3399 internal.college-server.com:3389 without the 4 in start , I did everything you mentionedBleeding
did you started the PuTTY session and logged in via SSH, before you tried the RDP client?Subduct
yes the 4 in the start indicates IPv4 is used, but than I thought it's better to use "Auto", but I forgot to adjust the example.Subduct
Crucial was the last sentence. internal.college-server.com:3389. This :3389Poult

© 2022 - 2024 — McMap. All rights reserved.