Saturday, July 20, 2019

How to install Kali Linux in Virtualbox


     Installing Kali Linux


There are two options for installing Kali: install it as a virtual machine inside the current operating system or install it in the main machine as the main operating system. Virtual machine works exactly the same as using it as the main machine; it will be completely isolated from our computer running inside VirtualBox. If we break it, or mess things up, it would be very easy to fix. It's very easy to go back to other snapshots or configurations, and we won't lose any functionality by using it as a virtual machine. That is why we always use it this way

The steps for installing Kali Linux are as follows:  

1.       Download the VirtualBox version for your computer. 

2.       After setting up VirtualBox, download Kali Linux, available at:

                  



3.       Scroll down, making sure to click on the Kali Linux VirtualBox Images, not on the VMware; then, download the version of Kali that's compatible with your system. So, if you have a 64-bit computer, download the 64-bit, and if you have a 32-bit computer, download the 32-bit.

4.       After downloading it, you should get a file with a .ova extension; you will have the name followed by the .ova extension, as shown here:

            

5.       To install this in VirtualBox, all we have to do is double-click on the file. You will see a window that will allow you to import the virtual machine. We're going to keep everything the same for now and we're just going to click on the Import button. That's it; the virtual machine is ready to be used:

           

6.       Before we start, we will look at how to modify some of the settings. We're going to click on the Kali-Linux tab, which can be seen on the left side of the window. Then, we're going to click on the Settings. The first thing that we are going to do here is go to System and modify the amount of RAM it has. Depending on how much RAM you have on your computer, you can give this a 2, but 1 GB is enough for Kali. Usually, I leave it at 2, because I have 16 GB of RAM.

7.       Also, when you click on the Processors tab, you'll see that, by default, we have two processors assigned to it. Again, I have 8 CPUs, so 2 is not going to cause too much pressure on my computer; but 1 CPU is also enough for Kali.

8.       Now, we're going to go to the Network settings, and we're going to set this to use a NAT network. Sometimes, when we set this to a NAT Network, we won't see a network name in here; for that, please check out the link https://www         .youtube             . com/watch      ?v=y0PMFg          -oAEs and it will show how to create a NAT Network. This setting is basically going to create a virtual network that our host machine will be the router for, and then all of the virtual machines are going to be clients connected to this network. So, they're going to get internet connection from the host machine and, at the same time, all of my virtual machines will be connected to a virtual network. This is very handy, because my virtual machines will be able to communicate with each other; we can use one of them to hack into another, and we can use it to test network attacks, and much more.
This will allow my virtual machines to have internet connection, and it will also allow them to communicate with each other, all of this will be done through a virtual network. It will not use any of your wireless adapters or any of the wireless cards; it will create a virtual Ethernet network, so as far as the virtual machines are concerned, they're connected to a network through an Ethernet cable.
9.       We can now click on OK and start our virtual machine.

10.    Now, to start it, all we have to do is click on the Start button. Then, click inside the virtual machine, and hit Enter; now we are inside the virtual machine:

           

11.    Now it's asking us for the username, and the default username is root, and then it's asking us for the password, and the default password is the reverse of that, which is toor. Since we installed this using the ready image, we can just click on the green button, or we can go to View | Full-screen; the screen will automatically resize to the size of our screen.

12.    Now, note that top-right hand side of the screen, we should actually see a network icon, because we set this machine to use a NAT network. If we don't have a network icon, it means that the machine isn't connected to the NAT network, so if we open the browser, we will see that it's not connected to the internet.

13.    To fix this issue, we just have to go to the top of the screen, and it will display menus. Going to Devices | Network, we can click on Connect Network Adapter as shown in the following screenshot:

             

We only have to do this once, and then the virtual machine will automatically connect to the NAT network. Once this is done, in just a few seconds, we will have a network icon appear, and if we click on it, we will get connected to a wired network.
14.    As we can see in the following screenshot, it says Wired Connected, so Kali thinks it's connected to a wired network:
             

Now, if we just click Try Again in the browser, we will see internet working.
Also, like I said, you won't lose any functionality when you install Kali Linux as a virtual machine. It's actually better to install it as a virtual machine, because it's completely isolated from your computer, and it will be very easy to fix if things go wrong.