How to install Kali Linux on Raspberry Pi

In this tutorial we are going to learn how to install Kali Linux on Raspberry Pi  4 or in lower versions. To know this first we need to know what is Raspberry Pi ?


In this tutorial we are going to make our own portable hacking machine using Raspberry Pi


What is Raspberry Pi ?

Raspberry Pi 4

Raspberry Pi is a very low cost ARM based single board computer. Raspberry Pi is very small in size like credit card which makes it very portable. Raspberry Pi have low powered ARM based processor and few amount of RAM (1GB/2GB/4GB) and it runs Kali Linux smoothly. That because it becomes very handy in penetration testing.

Why should we use Kali Linux in Raspberry Pi ?


In some cases client may ask to do us a perfect red team attack. In that cases, going in an office with a laptop in hand may look suspicious. In that case we can use a Raspberry Pi to perform some grate attacks on the network.

So what we need to do this task ?

  • Raspberry Pi 4 (Older versions will also work)
  • Micro SD card (High speed recommended class 10)
  • Power Supply (USB type C for Raspberry Pi 4)
  • Micro HDMI to HDMI cable
  • Micro SD card reader

How to install Kali Linux on Raspberry Pi ?


Let's start, Raspberry Pi supports SD cards. The best way to install Kali Linux on Raspberry Pi is flashing it on memory card then inserting the memory card into Raspberry Pi Here we suggest Raspberry Pi 4 with 4GB RAM variant for faster performance.

To flash Kali Linux image file we need to download it from Offensive Security's website, and download the image file for our supported versions.

offensive-security

After downloading we can use many different ways to flash this Kali Linux image file on micro SD card. Windows user can try Etcher like software (This is super easy).

Linux or macOS users can do it easily by dd utility. Let plug our micro SD card to our PC using the card reader then we type following command to check our memory card's path:

fdisk -l
The screenshot is following:

checking path of our disks
Here /dev/sdb1 is our external device means our micro SD card
Here we can see our micro SD card's path as /dev/sdb1.

Now to flash Kali Linux on our micro SD card we need to extract the kali-linux-2019.3a-rpi3-nexmon-64.img.xz. We go to the folder where the image file downloaded and open a terminal in that directory or open a terminal and go to the directory where we have downloaded the image file and type following command

unxz kali-linux-2019.3a-rpi-nexmon-64.img.xz
Now the image file have been successfully extracted. It's time to flash it on memory card.


dd if=kali-linux-2019.3a-rpi-nexmon-64.img of=/dev/sdb1 bs=512k

This command will overwrite all existing data on our micro SD card and flash Kali Linux on micro SD card. So need to choose the path of our card very carefully. If we choose wrong path, we may wipe out our computer's hard disk!

The screenshot is following :

dd utility

Here we have flashed Kali image file, if we downloaded any other version of image file then we should give proper image file name in the command.

This process will take some time depending on our computer's speed.

After flashing process done, we plug the micro SD card in proper slot of Raspberry Pi and connect it with a monitor using HDMI cable and micro HDMI to HDMI cable. Raspberry Pi 4 did not have full size HDMI port, but older versions of Raspberry Pi have full size HDMI port in that case we no need the micro HDMI to HDMI converting cable.

After connecting monitor we just give power via power cable. Older versions of Raspberry Pi requires micro USB and Raspberry Pi 4 needs USB type C for power supply.

So we have flashed Kali Linux on and plugged it on Raspberry Pi. It will work as a hard disk  then we have connect with a display and then we give it power. Then we can see Kali Linux will successfully boot  up. This is how we can install Kali Linux on Raspberry Pi. But wait is this handy? We are using it for portability but we can't carry a monitor with us. Then what to do ? We may make a headless setup, where our mobile device will work as a screen of Raspberry Pi. The Raspberry Pi and mobile will connect through ssh in same WiFi network to know more read this. But we suggest to buy a 5 inch or 7 inch HDMI display for raspberry pi (We are using a 3.5 inch display) and use a power bank for power supply and use a mini Bluetooth keyboard with touch-pad. The all set up can easily fitted in pockets or hand bags.

Portable Pentest Machine


Now our portable hacking machine is ready. We can do any stuff with this Kali Linux. We will make more tutorials on Raspberry Pi and Kali Linux for those regular visit us and keep supporting by commenting and shearing. Comment how much you liked this tutorial and what can improve this set up ?
How to install Kali Linux on Raspberry Pi How to install Kali Linux on Raspberry Pi Reviewed by Kali Linux on November 21, 2019 Rating: 5

No comments:

Powered by Blogger.