January 28, 2018 · tutorial pentesting kalilinux ·

How to set up Kali Linux OS in cloud at Just $2.50/Month for penetration testing

Hello,

In this post, I will walk you through how to setup and install Kali Linux in one of the cheapest VPS providers for just $2.50/month. I've tried this personally, successfully deployed Kali Linux which is working fine so far and have decided to share this with Infosec community.This would be very handy for all penetration testers, Bug Hunters as it is hosted in the cloud. So, Here are the procedures to set up the beast in the cloud.

Procedures:

  1. Register User Account in Vultr
  2. Upload Minimal Kali Linux ISO
  3. Install Kali Linux Complete System
  4. Set up SSH server
  5. Fixing Network Interface Card (NIC) issue
  6. SpeedTest
  7. Bonus Tips & Advice

1) Register User Account in Vultr

Vultr provides various cloud hosting services to its clients.They have an interesting feature where users can upload and deploy their own custom operating system ISO such as Kali Linux, etc.During the time of write-up, They also provide cheapest VPS hosting with below specifications for just $2.50/Month in Los Angeles and Miami Locations.
0-1
Go to this Link, Register a user account and Make sure you pay for minimum payout before deploying servers.

2) Upload Minimal Kali Linux ISO

addiso

  • Wait for some time and the status of uploaded ISO will be changed to Available.
    1.iso_live

3) Install Kali Linux Complete System

  • Click the + sign on the right side of the application to deploy servers.

  • Choose the Server Location as 'Miami' which will unlock the cheapest VPS pricing $2.50/month
    2.serverlocation

  • Select the Uploaded Minimal Kali linux ISO 'minimal.iso' as server type
    3.select_iso_uploaded

  • You should be able to see and select VPS plan of $2.50/month.
    4.server_size

  • Fill the remaining fields and Click on 'Deploy Now' submit button to create the instance.

  • Status of your new instance should be running and click on 'View Console' as it's time to install Kali Linux on the box.
    55

  • Start the Kali Linux Installation and continue with next steps based on your preference.
    5.Kali_install

  • Choose only 'SSH server' & 'standard system utilities' during Software Selection.
    6.Kali_Software_selection

  • You will be able to see the Installation Complete screen if everything goes right.
    7.Kali_complete-1

  • Make sure to remove the uploaded custom ISO from Vultr server settings.Otherwise, your instance will get stuck on Installer Boot Menu during startup.
    8.Remove-ISO

  • Finally, we are able to access minimal Kali Linux via Console.Also, It should be capable of making Inbound/Outbound connections to the internet.
    9.ping

  • We have to install Kali Linux Complete System by using kali-linux-full metapackages.
    [email protected]:~# apt install kali-linux-full

  • Kali Linux Complete System is live now.
    msf

4) Set up SSH server

We don't want to access our box every time via Web Console.So, We can enable SSH Service from Kali Linux and can add that in the startup.By default, SSH service will not be enabled in Kali Linux.

  • Login to the box via Web console and Edit the 'sshd_config' file.
    [email protected]:~# nano /etc/ssh/sshd_config

  • Inside the 'sshd_config', Uncomment and Edit the following lines.
    Port 22
    .....
    .....
    PermitRootLogin yes

  • Enable the SSH service on startup by using following commands.
    [email protected]:~# systemctl start ssh
    [email protected]:~# systemctl enable ssh

5) Fixing Network Interface Card (NIC) issue

I have observed that kali linux is not configuring the network interface correctly after reboot.It changed interface from ens3 to eth0 and you cannot make Inbound/Outbound connections to internet.

To fix the Issue:

  • Check your network interface by using ifconfig command.

  • If you cannot find ens3 or eth0 interfaces , Type dhclient to automatically assign Static IP Address using DHCP protocol. Reconfirm it using ifconfig command and this fix is temporary.

  • In order to fix this issue permanently, We can use DHCP to automatically configure the interface by editing network interface configuration file.
    [email protected]:~# nano /etc/network/interfaces
    ................
    allow-hotplug eth0
    iface eth0 inet dhcp
    11.Ifaces

6) SpeedTest

I am getting Upload & Download speed in between 100-200 MB/sec. Have calculated it using 'speedtest-cli'.
Speedtest

7) Bonus Tips & Advice

You can use Tmux or Screen to keep the sessions on the server when you access the box via SSH.

After installing Kali Linux in Vultr, Don't forget to secure your box. As it is exposed on the internet, Keep updating security patches, Audit your server and do the necessary hardening.

With Great Power Comes Great Responsibility, Hacking into someone else’s systems are illegal. Make sure that you have explicit permission before breaking into other systems.Also, Read Vultr use policy.

Please feel free to comment if you have any Feedbacks/Questions

Comments powered by Disqus