Skip to main content

Change to KDE Plasma Desktop Environment

Installing KDE Plasma

Official Documentation: https://www.kali.org/docs/general-use/switching-desktop-environments/

Some deviations from the procedure for me:

  1. Run sudo apt install -y kali-desktop-kde, choose sddm
  2. Run sudo apt remove --purge --auto-remove -y *xfce* lightdm
  3. Reboot. With the removal of Xfce and LightDM, this should cause SDDM and KDE Plasma to become the default

If required, be sure to change from Plasma (Wayland) to Plasma (X11) 

image.png

Click Desktop Session: Plasma (Wayland) and change to X11

XRDP on KDE Plasma

XRDP Server on KDE Plasma | 0xBEN | Notes (benheater.com)

PolKit Network Manager Prompt

At login, policy manager keeps prompting for a password allow my non-root user to control the network manager service. We need to add a PolKit local authority config to give the non-root user account permissions to do specific things on the system.

image.png

Press Details to expand and view the desired Action of the PolKit prompt. This will inform the configuration shown below. Now, let's take a look at the default PolKit policy for org.freedesktop.NetworkManager.network-control

less /usr/share/polkit-1/actions/org.freedesktop.NetworkManager.policy

When browsing the file with less press the / key and search for org.freedesktop.NetworkManager.network-control, then press Enter. Below, we can see the default policy.

  <action id="org.freedesktop.NetworkManager.network-control">
    <description>Allow control of network connections</description>
	
    <!-- ... removed for brevity ... -->
	<!-- ... removed for brevity ... -->
	<!-- ... removed for brevity ... -->

    <message xml:lang="as">চিস্টেম নীতিয়ে নেটৱৰ্ক সংযোগসমূহৰ নিয়ন্ত্ৰণ প্ৰতিৰোধ কৰে</message>
    <defaults>
      <allow_any>auth_admin</allow_any>
      <allow_inactive>yes</allow_inactive>
      <allow_active>yes</allow_active>
    </defaults>
  </action>

In the <defaults></defaults> section is where the magic happens. The <allow_*> sections refer to how the policy is applied depending on the user session state.

<allow_any>auth_admin</allow_any> -- specifies the requirements whether the user is active or inactive
Require admin privileges
- This action is going to take precedence over the other two.

allow_inactive>yes<allow_inactive> -- requirements for an inactive session, so allow changes when inactive
allow_active>yes<allow_active> -- requirements for an active session, so allow changes when active

sudo apt install -y polkitd-pkla
sudo nano /etc/polkit-1/localauthority/50-local.d/50-allow-network-manager.pkla

We're going to set the policy to yes for the user ben (in my case), as we want this user to be able to make modifications to the service when logged in.

[Network Manager All Users]
Identity=unix-user:ben;
Action=org.freedesktop.NetworkManager.network-control
ResultAny=yes
ResultInactive=yes
ResultActive=yes
sudo systemctl restart polkit.service

Setting up Meta+Shift+S Screen Capture

Configure KDE Spectacle

Open Spectacle

image.png

Click Configure

image.png

General

image.png

Shortcuts

image.png