One-click SSH Tunnel with RDP (from Linux to a remote Windows PC)

Related: Windows laptop to Windows SSH / RDP

We assume a remote Windows PC with SSH Cygwin Windows server or remote Linux PC with XRDP.

Remote PC IP Remote PC SSH port Remote PC RDP port
1.2.3.4 22 (open TCP firewall) 3389 (blocked by remote PC firewall)

create a bash script rdpmypc.sh on your laptop:

#!/bin/bash

ssh -f -L 3391:localhost:3389 [email protected] sleep 1;

xfreerdp /v:localhost:3391

Then type

chmod +x rdpmypc.sh

and use by

./rdpmypc.sh

Other options

click for advanced freerdp options (e.g. limited bandwidth)

Reference

xfreerdp command line options

Leave a Comment