Mstsc Client



Remote Desktop Connection Client. The Remote Desktop Client is used to connect to a system running Remote Desktop Services. Like the Remote Desktop Role, there are many options available with the Remote Desktop Client. So, again, we will give a basic overview of the client and focus on the security-related features. MSTSC, a command within Windows, is used to run remote desktop.Hence, you can also refer to the MSTSC as a remote desktop command. When you are on the same network or know the IP address of a remote computer, you are able to utilize MSTSC to establish the connection.

Updated 14/04/2021
Thin Clients, are computers which are optimized to establish a remote connection to a server and run using the remote resources. Usually those systems are not meant to be used for intensive tasks or gaming and they are mostly found in office environments. In the following guide you will find out how to use a Raspberry PI to connect to a local Windows Computer using Microsoft’s RDP Protocol.
Every version of Microsoft Windows following the release of Windows XP includes a Remote Desktop Connection (RDC) client (mstsc.exe). The Remote Desktop Connection is accomplished through the Client using the Remote Desktop Protocol a proprietary Microsoft Protocol which provides a graphical interface to connect to another computer.

Requirements

1) A computer running Microsoft Windows XP or later.
2) A Raspberry PI Device. (Prefer a Raspberry PI 3 or 4 for performance reasons)
3) Network connectivity between the two devices. (If the devices are not in the same local network, port forwarding must be enabled at the router of the Computer’s network.)

Preparation

Mstsc Client

Enable Remote Connections on Microsoft Windows 10

1) Open Control Panel

2) Click on System and Security

Mstsc Client

3) At the 'System' section, click Allow remote access

4) A new window will pop up. Select the Remote tab.
5) Under the 'Remote Desktop' section:

  • check the Allow remote connections to this computer option
  • check the Allow connections only from computers running Remote Desktop with Network Level Authentication option.
  1. Click OK and close the window.

Allow only Specific Users to login remotely. [Optional]

1) From the Remote Tab, click the Select Users… button

2) In the popup window click on Add button

2) Type the preferred username(s) using commas to separate them

!

3) Click the Check Names button, to validate username(s). If username(s) is/are valid username(s) on the current computer then the computer’s name will be prepended to the username(s).

Raspberry PI Setup

  1. Prepare a new sd-card with RaspiOS Lite (Version Used for this tutorial: January 11th 2021)
  2. In the boot partition of the sd-card create an empty file, name it 'ssh' and make sure it has no extension.
  3. Insert the SD card in your Raspi, connect it to your local network and power it up.
  4. Establish an SSH connection to the raspi using the default credentials (pi/raspberry). Use the official guides for Windows or Linux or Mac if you haven’t use SSH before.
  5. After connecting using SSH, update and upgrade your distribution
  6. Install OpenBox Windows Manager and x11 Windowing System by running the following command.
  1. Next, Install Remmina, an opensource Remote Desktop client with RDP support.

8.Make a configuration file at your home directory '/home/pi' and name it 'windows.remmina'.

  1. Add the following contents to the configuration file (use: sudo nano /home/pi/windows.remmina): Change server from xxx.xxx.xxx.xxx to your computer’s IP address and username to the computer’s login username. The password will be requested when remmina run.

  2. Next, edit the file /home/pi/.profile (use: nano /home/pi/.profile) and append the following line at the end of the file.

  3. Configure xinitrc by editing /etc/X11/xinit/xinitrc (use: sudo nano /etc/X11/xinit/xinitrc) :
    Comment out the following line:

    and add the following line:

  4. Lastly, edit openbox configuration file (use: sudo nano /etc/xdg/openbox/autostart) and type the following commands at the end of the file to disable any form of Screen Saver, Screen Blanking and Power Management and set Remmina to launch when launching openbox :

  5. Configure console autologin
    Run Raspberry PI configuration by typing:

Mstsc

Select 'System Options'

At the next screen select 'S5 Boot / Auto Login'

And finally, select 'B2 Console Autologin'

Use the Arrow Keys (Right arrow twice) to move to the Finish Button

Before Reboot confirmation connect your Raspberry to an external screen and attach a Mouse and a Keyboard in order to be ready for the next step.

Establishing an RDP Connection

  1. At this point everything is ready, your Raspberry will boot to OpenBox and Remmina will open asking to Accept the Certificate for the connection. Click on YES

  2. Now Remmina will ask for the password:

  3. Finally, connection established, toggle fullscreen and you are ready to go!

Extra Functionality

Shutdown Hardware Button

You can also add a Power On / Off button to your Raspberry PI using the information from the Raspberry PI Drone post

Show Desktop’s Background instead of Black Screen

Versions

Added 14/04/2021
By changing 'quality' property in the windows.remmina file from 0 to 9 your backround will be visible

Mstsc Client Logging

Full Screen connection

Rd Client Win 10

Added 14/04/2021
By changing 'viewmode' property in the windows.remmina file from 1 to 4 the connection will start in full screen.