Kali Linux on Azure – Install Guide

Azure supports the most common Linux distributions, including Red Hat, SUSE, Ubuntu, CentOS, Debian, and CoreOS, with more on the way. Create your own Linux virtual machines (VMs) or choose from hundreds of pre-configured images available in the Azure Marketplace.

At the core, “Microsoft ♥ Linux” is driven by what Microsoft heard from customers, and it goes that way: you running workloads on Windows,  you can run workloads on Linux, you running these workloads in your on-premises datacenters, hosted at service providers, and in public clouds or even private cloud. You want it all to work and to work together regardless of the operating system.

If we talk about Linux and security, we must mention the Linux security distro. One of the most excellent tools that many security professionals use daily is the KALI Linux penetration testing platform. Therefore Microsoft adds it to their cloud with all other Linux distros.

Microsoft ♥ Linux

Microsoft ♥ Linux

The KALI Linux, this distro is built and maintained by Offensive Security, an organization that also provides extensive training on the platform and various other security and penetration testing topics.

Note: this blog post is the first part of the KALI Linux installation, the other two pieces will be focused on KALI Linux configuration, and the third will be about security tool customization.

About Kali Linux

KALI Linux is a Security Distribution of Linux specifically designed for digital forensics and penetration testing. It was developed by Mati Aharoni and Devon Kearns of Offensive Security through the rewrite of BackTrack.

BackTrack was their previous information security Operating System. The first iteration of Kali Linux Kali 1.0.0 was introduced in March 2013. Offensive Security currently funds and supports Kalin Linux.

KALI Linux has over 600 preinstalled penetration-testing applications to discover. Each program with its unique flexibility and use case. Kali Linux does an excellent job separating these useful utilities into the following categories:

  • Information Gathering
  • Vulnerability Analysis
  • Web Applications
  • Exploitation Tools
  • Forensics Tools
  • Wireless Attacks
  • Reverse Engineering
  • Password Attacks

Kali Linux, who uses and Why?

Kali Linux is an unusual operating system, as it’s one of the few platforms openly used by both good actors and bad actors. Security Administrators and Black Hat Hackers use this operating system extensively, the first to detect and prevent security breaches and the second to identify and possibly exploit security breaches.

The number of tools configured and preinstalled on the operating system makes KALI Linux the swiss army knife in any security professional’s toolbox.

Security Roles that use KALI Linux

  • CISO – CISO or Chief Information Security Officers use KALILinux to internally audit their environment and discover if any new applications or rouge configurations have been put in place.
  • White Hat Hackers – White Hat Hackers, similar to Pen Testers, use KALI Linux to audit and discover vulnerabilities present in an environment.
  • Black Hat Hackers – Black Hat Hackers utilize KALI Linux to discover and exploit vulnerabilities. Kali Linux also has numerous social engineer applications, which can be utilized by a Black Hat Hacker to
  • Grey Hat Hackers – Grey Hat Hackers lie in between White Hat and Black Hat Hackers. They will utilize Kali Linux in the same methods as the two listed above.
  • Pen Testers – Pen Testers utilize Kali Linux to audit environments and perform reconnaissance on corporate environments they have been hired to review.
  • Forensic Engineers – Kali Linux posses a “Forensic Mode,” which allows a Forensic Engineer to perform data discovery and recovery in some instances.
  • Security Administrators – Security Administrators are responsible for safeguarding their institution’s information and data, and they use KALI Linux to review their environment and ensure there are no easily discoverable vulnerabilities.
  • Network Administrators – Network Administrators are responsible for maintaining an efficient and secure network. They use KALI Linux to audit their network. For example, Kali Linux can detect rogue access points.
  • Security Enthusiast – Computer Enthusiast is a pretty generic term. Still, anyone interested in learning more about networking or computers, in general, can use KALI Linux to learn more about Information Technology, networking, and common vulnerabilities.

KALI Linux Installation Methods

KALI Linux can be installed using the following methods:

  • Physical Hardware – Utilizing a Kali ISO image, Kali Linux can be installed directly onto a PC or laptop. This method is best if you have a spare pc and are familiar with Kali Linux. If you plan or do any access point testing, installing Kali Linux directly onto a Wi-Fi enabled laptop is recommended.
  • Virtualized (VMware, Hyper-V, VirtualBox, etc.) – Kali Linux supports the most known hypervisors and can be easily into the most popular ones. Pre-configured images are available for download, or an ISO can be used to install the operating system into the preferred hypervisor manually.
  • USB Boot Disc – Utilizing Kali Linux’s ISO, a boot disc can be created to either run Kali Linux on a machine without actually installing it or for Forensic purposes.
  • Windows 10 – Kali Linux can now natively run on Windows 10 via the command-line.
  • Cloud – Microsoft Azure and even Amazon AWS that provides Kali Linux’s popularity with dedicated images for Kali Linux.
Kali Linux

Kali Linux

Install Kali Linux on Microsoft Azure

The Kali Linux distro is available without additional cost on Azure. You can find it in the list of operating systems or images you can deploy like any other Windows or Linux distro.

Kali Linux is available on Azure Marketplace, and to do this, go to Azure Marketplace. There, you’ll see a page similar to the one shown below. Click on the “Get It Now” button to request the KALI Linux distro.

Kali Linux

Kali Linux

Prepare SSH Key

SSH KEYS allows us to connect to VMs without using passwords but bypassing a private key that you or your organization can manage.

The SSH Key creation steps are:

  • Open bash and type the following command: $ ssh-keygen -t rsa -b 2048 -C "KALI-SSH-Key"

Note: Keyname: server-key and Passphrase: something memorable

  • Copy the contents of server-key.pub with the following command: $ cat server-key.pub

The action should look like this:

Kali Linux

Kali Linux

Kali Linux

Kali Linux

The following SSH Key is required for the KALI Linux creation.

Install KALI Linux

There’s another way to install KALI Linux, and it’s from virtual machine creation. To install Kali Linux on Azure, follow these actions:

  • From Azure Portal, create a new virtual machine.
  • From the Virtual machine, add a new virtual machine and find the Kali Linux image.

  • Next, go to the “Authentication type” and choose the relevant authentication method – in this example and recommended authentication, we can use “SSH.”
  • The add “Username” and “SSH public key” – you need to generate this key before
  • Next, add an inbound rule for SSH port – port 22
  • Then, make sure to finish the other and common settings and create the Kali machine.

 

That all, after 10 minutes, the Kali Linux will be installed and ready for post configuration, package installation, and security tools configuration/

Connect to KALI

Once KALI Linux is installed, you can connect to the distro via ssh or Azure CLI using batch.

First, go to connect and pick up the public IP address and the Login creds.

The open Bash from Azure Portal and type the following command:ssh -i kaliazure eadmin@65.52.136.46 -v

Note: make sure to replace the login account and the IP address

Once the connection start to run, you will require to type the password.

Note: the password from SSH key generation

Kali Linux on Azure – Install Guide

Azure supports the most common Linux distributions, including Red Hat, SUSE, Ubuntu, CentOS, Debian, and CoreOS, with more on the way. Create your own Linux virtual machines (VMs) or choose from hundreds of pre-configured images available in the Azure Marketplace.
At the core, “Microsoft ♥ Linux” is driven by what Microsoft heard from customers, and it goes that way: you running workloads on Windows,  you can run workloads on Linux, you running these workloads in your on-premises datacenters, hosted at service providers, and in public clouds or even private cloud. You want it all to work and to work together regardless of the operating system.
If we talk about Linux and security, we must mention the Linux security distro. One of the most excellent tools that many security professionals use daily is the KALI Linux penetration testing platform. Therefore Microsoft adds it to their cloud with all other Linux distros.

Microsoft ♥ Linux

Microsoft ♥ Linux


The KALI Linux, this distro is built and maintained by Offensive Security, an organization that also provides extensive training on the platform and various other security and penetration testing topics.
Note: this blog post is the first part of the KALI Linux installation, the other two pieces will be focused on KALI Linux configuration, and the third will be about security tool customization.

About Kali Linux

KALI Linux is a Security Distribution of Linux specifically designed for digital forensics and penetration testing. It was developed by Mati Aharoni and Devon Kearns of Offensive Security through the rewrite of BackTrack.
BackTrack was their previous information security Operating System. The first iteration of Kali Linux Kali 1.0.0 was introduced in March 2013. Offensive Security currently funds and supports Kalin Linux.
KALI Linux has over 600 preinstalled penetration-testing applications to discover. Each program with its unique flexibility and use case. Kali Linux does an excellent job separating these useful utilities into the following categories:

  • Information Gathering
  • Vulnerability Analysis
  • Web Applications
  • Exploitation Tools
  • Forensics Tools
  • Wireless Attacks
  • Reverse Engineering
  • Password Attacks

Kali Linux, who uses and Why?

Kali Linux is an unusual operating system, as it’s one of the few platforms openly used by both good actors and bad actors. Security Administrators and Black Hat Hackers use this operating system extensively, the first to detect and prevent security breaches and the second to identify and possibly exploit security breaches.
The number of tools configured and preinstalled on the operating system makes KALI Linux the swiss army knife in any security professional’s toolbox.

Security Roles that use KALI Linux

  • CISO – CISO or Chief Information Security Officers use KALILinux to internally audit their environment and discover if any new applications or rouge configurations have been put in place.
  • White Hat Hackers – White Hat Hackers, similar to Pen Testers, use KALI Linux to audit and discover vulnerabilities present in an environment.
  • Black Hat Hackers – Black Hat Hackers utilize KALI Linux to discover and exploit vulnerabilities. Kali Linux also has numerous social engineer applications, which can be utilized by a Black Hat Hacker to
  • Grey Hat Hackers – Grey Hat Hackers lie in between White Hat and Black Hat Hackers. They will utilize Kali Linux in the same methods as the two listed above.
  • Pen Testers – Pen Testers utilize Kali Linux to audit environments and perform reconnaissance on corporate environments they have been hired to review.
  • Forensic Engineers – Kali Linux posses a “Forensic Mode,” which allows a Forensic Engineer to perform data discovery and recovery in some instances.
  • Security Administrators – Security Administrators are responsible for safeguarding their institution’s information and data, and they use KALI Linux to review their environment and ensure there are no easily discoverable vulnerabilities.
  • Network Administrators – Network Administrators are responsible for maintaining an efficient and secure network. They use KALI Linux to audit their network. For example, Kali Linux can detect rogue access points.
  • Security Enthusiast – Computer Enthusiast is a pretty generic term. Still, anyone interested in learning more about networking or computers, in general, can use KALI Linux to learn more about Information Technology, networking, and common vulnerabilities.

KALI Linux Installation Methods

KALI Linux can be installed using the following methods:

  • Physical Hardware – Utilizing a Kali ISO image, Kali Linux can be installed directly onto a PC or laptop. This method is best if you have a spare pc and are familiar with Kali Linux. If you plan or do any access point testing, installing Kali Linux directly onto a Wi-Fi enabled laptop is recommended.
  • Virtualized (VMware, Hyper-V, VirtualBox, etc.) – Kali Linux supports the most known hypervisors and can be easily into the most popular ones. Pre-configured images are available for download, or an ISO can be used to install the operating system into the preferred hypervisor manually.
  • USB Boot Disc – Utilizing Kali Linux’s ISO, a boot disc can be created to either run Kali Linux on a machine without actually installing it or for Forensic purposes.
  • Windows 10 – Kali Linux can now natively run on Windows 10 via the command-line.
  • Cloud – Microsoft Azure and even Amazon AWS that provides Kali Linux’s popularity with dedicated images for Kali Linux.
Kali Linux

Kali Linux

Install Kali Linux on Microsoft Azure

The Kali Linux distro is available without additional cost on Azure. You can find it in the list of operating systems or images you can deploy like any other Windows or Linux distro.
Kali Linux is available on Azure Marketplace, and to do this, go to Azure Marketplace. There, you’ll see a page similar to the one shown below. Click on the “Get It Now” button to request the KALI Linux distro.

Kali Linux

Kali Linux

Prepare SSH Key

SSH KEYS allows us to connect to VMs without using passwords but bypassing a private key that you or your organization can manage.
The SSH Key creation steps are:

  • Open bash and type the following command: $ ssh-keygen -t rsa -b 2048 -C "KALI-SSH-Key"

Note: Keyname: server-key and Passphrase: something memorable

  • Copy the contents of server-key.pub with the following command: $ cat server-key.pub

The action should look like this:

Kali Linux

Kali Linux


Kali Linux

Kali Linux



The following SSH Key is required for the KALI Linux creation.

Install KALI Linux

There’s another way to install KALI Linux, and it’s from virtual machine creation. To install Kali Linux on Azure, follow these actions:

  • From Azure Portal, create a new virtual machine.
  • From the Virtual machine, add a new virtual machine and find the Kali Linux image.

  • Next, go to the “Authentication type” and choose the relevant authentication method – in this example and recommended authentication, we can use “SSH.”
  • The add “Username” and “SSH public key” – you need to generate this key before
  • Next, add an inbound rule for SSH port – port 22
  • Then, make sure to finish the other and common settings and create the Kali machine.


 
That all, after 10 minutes, the Kali Linux will be installed and ready for post configuration, package installation, and security tools configuration/

Connect to KALI

Once KALI Linux is installed, you can connect to the distro via ssh or Azure CLI using batch.
First, go to connect and pick up the public IP address and the Login creds.

The open Bash from Azure Portal and type the following command:ssh -i kaliazure eadmin@65.52.136.46 -v
Note: make sure to replace the login account and the IP address

Once the connection start to run, you will require to type the password.
Note: the password from SSH key generation

You may also like...

2 Responses

  1. Sam Adeyemi says:

    How do I get the GUI? I only have the CLI

  1. December 13, 2021

    […] Create Kali VM based on Kali Linux On Azure – Install Guide […]

Leave a Reply

error: Content is Protected !!
%d bloggers like this: