Wazzup Guys, Today I'm going to show you how to install KaliLinux on the Raspberry Pi.
First of all what is the Raspberry Pi?
First of all what is the Raspberry Pi?
The Raspberry Pi is a low cost, credit-card sized computer that plugs into a computer monitor or TV, and uses a standard keyboard and mouse. It is a capable little device that enables people of all ages to explore computing, and to learn how to program in languages like Scratch and Python. It’s capable of doing everything you’d expect a desktop computer to do, from browsing the internet and playing high-definition video, to making spreadsheets, word-processing, and playing games.
As you can read the Raspberry Pi is low cost and that is true because you can buy one for $35 only! There are 5 versions:
The Raspberry Pi Module development kit, The Raspberry Pi model A The Raspberry Pi B The Raspberry Pi A+ The Raspberry Pi B+ and the Raspberry Pi 2
For this tutorial I use the Raspberry Pi 2 but you can do this on the B or B+
version as well
Things we need are
~~~~~Burn to SD card~~~~
First of all, insert the micro SD card in your PC. Then go to
https://www.offensive-security.com/kali-linux-vmware-arm-image-download/
And download the Raspberry Pi (2) image.
The Raspberry Pi Module development kit, The Raspberry Pi model A The Raspberry Pi B The Raspberry Pi A+ The Raspberry Pi B+ and the Raspberry Pi 2
For this tutorial I use the Raspberry Pi 2 but you can do this on the B or B+
version as well
Things we need are
- A (micro) SD card
- A Raspberry Pi (2)
- A Wifi Dongle
- A micro USB charger
- A HDMI cable
- Win 32 Disk Image Burner
- 7zip
~~~~~Burn to SD card~~~~
First of all, insert the micro SD card in your PC. Then go to
https://www.offensive-security.com/kali-linux-vmware-arm-image-download/
And download the Raspberry Pi (2) image.
Because the image is in img.xz format you need to open the file with 7zip. Open the .img.xz file and extract the real .img file. Then open Win 32 Disk Image Burner and select the Kali Image and burn it to your (micro) SD card...
After that insert the (micro) SD card Micro usb and HDMI cable in your Raspberry Pi. Now your Raspberry Pi is turned on and your Raspberry Pi is booting. After a while Kali asks you a username and a password. the username = root and the password = toor
~~~~~Remote~~~~~
Because the Raspberry Pi is really low powered we can use it as a kind of a server.
Run the command startx for starting kali in the graphical enviroment. Connect your WiFi network and reboot the Raspberry Pi with the command reboot. Enter the username and password again but don't run the command startx. What we're going to do now is installing some tools for using Kali remotely. The first one is VNC. Install it by typing apt-get install tightvncserver. start it by typing tightvncserver. The second tool is (open) ssh.It's running on port 22 and Methink it is always on but I am not sure about that so start it by typing in service ssh start.
~~~~~Remote~~~~~
Because the Raspberry Pi is really low powered we can use it as a kind of a server.
Run the command startx for starting kali in the graphical enviroment. Connect your WiFi network and reboot the Raspberry Pi with the command reboot. Enter the username and password again but don't run the command startx. What we're going to do now is installing some tools for using Kali remotely. The first one is VNC. Install it by typing apt-get install tightvncserver. start it by typing tightvncserver. The second tool is (open) ssh.It's running on port 22 and Methink it is always on but I am not sure about that so start it by typing in service ssh start.
Secure Shell, or SSH, is a cryptographic (encrypted) network protocol for initiating text-based shell sessions[clarification needed] on remote machines in a secure way.
This allows a user to run commands on a machine's command prompt without them being physically present near the machine. It also allows a user to establish a secure channel over an insecure network in a client-server architecture, connecting an SSH client application with an SSH server.[1] Common applications include remote command-line login and remote command execution, but any network service can be secured with SSH. The protocol specification distinguishes between two major versions, referred to as SSH-1 and SSH-2.
Now we can use our Raspberry Pi fully remotely so you don't need that HDMI cable anymore :)
~~~~~Expand the root partition and install all tools~~~~~
Once you're connected to your Raspberry Pi (Via VNC) you can see two strange things. The first is that there are no kali tools installed! The second thing is that the root partition is really small (64mb or something like that).
We can expand the root partition with the following commands:
wget -O /boot/raspi-expand-rootfs.sh http://dl.linhost.info/file1/raspi-expand-rootfs.sh
chmod +x /boot/raspi-expand-rootfs.sh
sh /boot/raspi-expand-rootfs.sh
Okay reboot the Raspberry Pi with the reboot command . The second thing we have to do now is install all the kali tools by typing apt-get install kali-linux-full. Before you press enter I want to say this: There are about 147 tools you have too install so this it could take a while ;)
~~~~~ARM~~~~~
Your Raspberry Pi is an ARM device. It's really hard to explain what ARM is and I am not a computer scientist but ARM stands for Acorn RISC Machine and it's used in devices like Phones Televisions Routers NAS-devices and portable game consoles. 98% of phones are ARM based and the Raspberry Pi is ARM based too. The processor architecture or Instruction Set Architecture (ISA) is the kind of the machine language the processor speaks. So keep in mind most packages you download on the internet are x86-64 or i386 based and may not work.
~~~~~ Cobalt Strike~~~~~
The combination of KaliLinux and the Raspberry Pi is really powerfully and to prove that I want to give you the example of Cobalt Strike.
~~~~~Expand the root partition and install all tools~~~~~
Once you're connected to your Raspberry Pi (Via VNC) you can see two strange things. The first is that there are no kali tools installed! The second thing is that the root partition is really small (64mb or something like that).
We can expand the root partition with the following commands:
wget -O /boot/raspi-expand-rootfs.sh http://dl.linhost.info/file1/raspi-expand-rootfs.sh
chmod +x /boot/raspi-expand-rootfs.sh
sh /boot/raspi-expand-rootfs.sh
Okay reboot the Raspberry Pi with the reboot command . The second thing we have to do now is install all the kali tools by typing apt-get install kali-linux-full. Before you press enter I want to say this: There are about 147 tools you have too install so this it could take a while ;)
~~~~~ARM~~~~~
Your Raspberry Pi is an ARM device. It's really hard to explain what ARM is and I am not a computer scientist but ARM stands for Acorn RISC Machine and it's used in devices like Phones Televisions Routers NAS-devices and portable game consoles. 98% of phones are ARM based and the Raspberry Pi is ARM based too. The processor architecture or Instruction Set Architecture (ISA) is the kind of the machine language the processor speaks. So keep in mind most packages you download on the internet are x86-64 or i386 based and may not work.
~~~~~ Cobalt Strike~~~~~
The combination of KaliLinux and the Raspberry Pi is really powerfully and to prove that I want to give you the example of Cobalt Strike.
Cobalt Strike is threat emulation software. Execute targeted attacks against modern enterprises with one of the most powerful network attack kits available to penetration testers. This is not compliance testing.
First of all you have to install armitage (cobaltstrike is the paid version of armitage).
Do this by running the command apt-get install armitage.
Once it is installed start the services metasploit and postgresql by typing
service metasploit start
service postgresql start
or service metasploit start; service postgresql start.
The next and the most importand thing is that we need to tell kali to use Java 1.7 by default. Becouse the Raspberry Pi is an ARM device we don't have to type
update-java-alternatives --jre -s java-1.7.0-openjdk-i386
or
update-java-alternatives --jre -s java-1.7.0-openjdk-amd64
but
update-java-alternatives --jre -s java-1.7.0-openjdk-armhf
Amazing now you can use cobaltstrike such as on a normal PC :)
That was it for Today guys
Happy Hunting
@ClaimItToYou
Do this by running the command apt-get install armitage.
Once it is installed start the services metasploit and postgresql by typing
service metasploit start
service postgresql start
or service metasploit start; service postgresql start.
The next and the most importand thing is that we need to tell kali to use Java 1.7 by default. Becouse the Raspberry Pi is an ARM device we don't have to type
update-java-alternatives --jre -s java-1.7.0-openjdk-i386
or
update-java-alternatives --jre -s java-1.7.0-openjdk-amd64
but
update-java-alternatives --jre -s java-1.7.0-openjdk-armhf
Amazing now you can use cobaltstrike such as on a normal PC :)
That was it for Today guys
Happy Hunting
@ClaimItToYou