kali linux configure xrdp remote desktop service

Original link: https://blog.frytea.com/archives/645/

75

The configuration of xrdp makes me full of doubts. Today, I completed the xrdp configuration under kali by mistake, and I can successfully remote desktop into kali. Here are some steps that may be necessary for future use.

First, follow the xrdp configuration script given by the kali official website:

 #!/bin/sh echo "[i] Updating and upgrading Kali (this will take a while)" apt-get update apt-get dist-upgrade -y echo "[i] Installing Xfce4 & xrdp (this will take a while as well)" apt-get install -y kali-desktop-xfce xorg xrdp echo "[i] Configuring xrdp to listen to port 3390 (but not starting the service)" sed -i 's/port=3389/port=3390/g' /etc/xrdp/xrdp.ini

After saving, sudo is executed, and xrdp is automatically configured.

If the download is slow, you can match the USTC Kali software source.

Then set the default command line to start, otherwise the remote desktop cannot be loaded:

 # 命令行启动$ systemctl set-default multi-user.target # 图形界面启动$ systemctl set-default graphical.target

Then enable the xrdp service:

 $ systemctl enable xrdp $ systemctl start xrdp

To prevent the ssl certificate from being unverifiable, add the xrdp user to the ssl-cert user group:

 sudo adduser xrdp ssl-cert

After that, you can restart and try to see if it is successful. Remember that the official configuration port is 3390 instead of 3389 :

 $ reboot

If that doesn’t work, configure this and try again:

 # To set the system default to xfce4:- $ **sudo update-alternatives --config x-session-manager** There are 3 choices for the alternative x-session-manager (providing /usr/bin/x-session-manager). Selection Path Priority Status ------------------------------------------------------------ * 0 /usr/bin/gnome-session 50 auto mode 1 /usr/bin/gnome-session 50 manual mode 2 /usr/bin/startxfce4 50 manual mode 3 /usr/bin/xfce4-session 40 manual mode Press to keep the current choice[*], or type selection number: **3** update-alternatives: using /usr/bin/xfce4-session to provide /usr/bin/x-session-manager (x-session-manager) in manual mode Try that

Then it should be fine. If not, please leave a message.

references

This article is reproduced from: https://blog.frytea.com/archives/645/
This site is for inclusion only, and the copyright belongs to the original author.