Creating a virtual network

The following diagram shows the general network topology we are going to use in our virtual lab environment:

In the upcoming section, we will assign an appropriate IP address to each virtual machine within our lab. Each virtual machine is interconnected using a virtual switch within the hypervisor. Routers are not required, as this is just a simple lab design.

A Windows Server 2008 machine is optional and is not required.

Let's see how to build a virtual network:

  1. If you're using VirtualBox, click on the menu icon on the right-hand side of Tools | Network:

A new window will open, giving you the option to Create, Remove, or modify the properties of a virtual network adapter. In this exercise, we are going to create a new virtual adapter, which will be used to connect each of our virtual machines within the hypervisor. This accomplishes the effect of a virtual switch.

  1. Click on Create to add a new virtual adapter:

Your host operating system will take a few minutes to create the new virtual network adapter on your computer.

  1. Once the virtual network adapter has been created, the network manager component within VirtualBox will automatically assign an IP address to the interface. However, we are going to configure the IP addressing scheme as per our preferences. To begin, simply select the virtual network adapter, and then click on Properties to modify the configurations.
  2. Ensure that you choose the option to configure the adapter manually, using the IP address and subnet mask shown in the following screenshot. Click Apply to register the configurations on the network adapter:

  1. Optionally, we can configure the Dynamic Host Configuration Protocol (DHCP) server on the virtual network adapter to provide a range of IP addresses to each virtual machine that is connected to this virtual network. If you would like to enable the DHCP service, please use the following configurations:

  1. For those of you who prefer VMware Workstation, we've got you covered. Configuring a virtual network within VMware Workstation is quite simple. Open the VMware Workstation application and select Edit | Virtual Network Editor..., as shown in the following screenshot:

  1. The User Access Control (UAC) on Windows will prompt you for administrator privileges. Upon providing the authorization, the Virtual Network Editor window will open. As you can see, there are three virtual network adapters present:

We are going to modify the VMnet1 virtual adapter. The host-only adapter creates a virtual network for all connected virtual machines and the host computer. This type of configuration allows all virtual machines to communicate seamlessly while isolated and in the absence of an internet connection.

  1. To modify the VMnet1 adapter, select the adapter and adjust your configurations, as shown in the following screenshot:

These configurations replicate those executed previously within Oracle VM VirtualBox.

Now that we have the knowledge required to build our virtual network using both Oracle VM VirtualBox and VMware Workstation Pro, let's begin installing virtual machines and setting up Kali Linux in our lab.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.141.35.60