Kali Linux 2 is the latest edition of Kali Linux, a desktop distribution designed for penetration testers and experienced security users.

By default, it uses a GNOME 3 desktop, but it’s possible to build a custom image using other popular desktop environments, like KDE, Xfce, and MATE. This tutorial will show you how to build a custom image with a KDE desktop.

Because KDE Plasma 5 is not yet available for this distribution, the desktop image you build will be powered by KDE 4.14.2. And it’s a lot easier to build the image from a running Kali Linux 2 desktop. So if you don’t have a Kali Linux 2 installation already, you may install one by downloading an installation image for your platform from here.

The computer I used for building the image has an Intel Core i3 processor inside, so it’s a powerful system. But even at that, the system froze on my first attempt. And that was because I had the IceWeasel Web browser and one other application running. To avoid the same issue, be sure to close all other running applications. Let the terminal be the only application that’s running, unless you have a system that’s more powerful than mine.

Step 1Update Kali Linux 2:
You’ll be using a shell terminal throughout, so launch a shell terminal, update the package database and upgrade the system using the following pair of commands:

# Uncommented lines are commands you must run
# 1. Update the package database

apt-get update

# 2. Apply available updates

apt-get upgrade

#
#

Step 2Install Required Packages:
You only need to install three extra packages that you need for the build. The packages are cdebootstrap, live-build, and live-image-kde-desktop. Install them using the following command:

# Uncommented line is command you must run
# Update the package database

apt-get install cdebootstrap live-build live-image-kde-desktop

#
#

Step 3Build Kali Linux 2 KDE Image:
Use these three commands to clone the repository and starting the build.

# Uncommented lines are commands you must run
# 1. Clone the repository

git clone git://git.kali.org/live-build-config.git

# 2. Change into the new directory

cd live-build-config

# 3. Build the image

./build.sh --distribution sana --variant kde --verbose

#
#

If the build is successful, you should have an ISO image of about 3.1 GB in size in the images directory, which you may then burn to a blank DVD or transfer to a USB stick. The screenshot below shows the KDE desktop installed from the built image.

Kali Linux 2 KDE desktop

Kali Linux 2 KDE desktop