Royal Military College of Canada
Department of Electrical and Computer
Engineering
EEE473 Computer Network Design
Dr G.S. Knight
Prof S. Leblanc
Lab 1 -
Exercise and Lab Preamble
During this course you will be working in a virtual environment. The
instructions below will guide you through the set-up required at the
beginning of each exercise and lab. Take the time to understand each
as it will improve your effectiveness during the many hours you will spend
in the lab.
Objectives
This lab aims to:
- Help you understand the use of a virtual environment
- Configure Network Interfaces
- Use basic Linux commands for system administration and network
configuration
Logging in to the "eee473
" host:
- Sit down at one of the host machines in the Computer Network Security
Lab 4112.
- Before you even touch the keyboard, observe the welcome
message. It likely says "
lab4112x
". Read this
as lab room number 4112 and machine number x
.
- Record your machine number
x
here: _____.
- Log onto the machine using the user-name: eee473.
Use this mnemonic to help you remember the password: 473
Communications Course in the Computer Network Security laboratory.
Note that this machine will be referred to as the host.
- This machine is running VMware to support the virtual machines (VM)
that will be used in this course; we will use Windows and Linux
virtual machines.
Part 1 - Starting the Windows virtual machine (Windows VM):
- To start the Windows virtual machine right click anywhere on the host
desktop and select:
Windows VM
- The Windows VM (Microsoft Windows XP Virtual Machine) will boot in a
VMware window. Be patient, it may take some time to load.
- Re-size the window or select Full Screen from the View menu of VMware.
- Be patient! - The VMware tools driver takes a long time to
load after boot - Wait and allow for VMware to re-size.
- Familiarize yourself with the applications installed within the
Windows VM. You will discover that this is a fairly simple Windows
installation. Find the location of some of the more frequently required,
but perhaps less known, applications such as:
- Command Prompt
-> All Programs -> Accessories -> Command Prompt
- You can create a short-cut by clicking and dragging the icon to
your desktop
- Network Connections
-> Control Panel -> Network Connections
- Printers
-> Printers and Faxes
- Matthews CD
-> Computer -> CompNetworking (G:)
- USB Drives, which you can use to capture information from the
Windows VM
- Ensure that the Windows VM is active and plug-in the USB drive in
the host; it will automatically mount to the
Windows VM.
- Ensure that you properly eject the drive by right-clicking the
safely remove hardware button
->Remove drive
- If you are working in Full Screen mode, minimize the Windows VM for
now by selecting the "iconify the window" button (traditional minimize)
in the VMware control panel.
Part 2 - Starting the Linux virtual machine (Linux VM):
- To start the Linux virtual machine right click anywhere on the host
desktop and select: Linux VM
- Be patient, the first time may be slow!
- The Linux VM (
OpenSUSE Linux
Virtual Machine) will boot
in a VMware window.
- Resize the window or select Full Screen from the
View
menu
of VMware. You may use both screens if you wish.
- Be patient - allow for VMware to re-size.
- Getting to know openSUSE:
- The installed Linux operating system on the Linux VM is
openSUSE
version 13.1.
- Throughout the course you will use many different
applications. Take a few minutes to familiarize yourself with
openSUSE
.
Note that most applications are available by clicking on the openSUSE
Applications Menu
on the left of the panel. Find the location of some of the more
frequently required applications.
- Applications available from the
Application Menu
include:

->
System -> xfce Terminal
- Again you can create a short-cut by long clicking and dragging
onto the desktop. Note that you will have to select "Mark
Executable" when prompted the first time it is run.

->
System -> Thunar File Manager

->
Internet -> Firefox

->
Accessories -> Leafpad
{a good general purpose text
editor}

->
Office -> LibreOffice Writer
{an Open Office word
processor}
- USB Drives, which you can use to capture information from the Linux
VM
- Ensure that the Linux VM is active and plug-in the USB drive in
the host; it will automatically mount to the Linux VM.
- Ensure that you properly eject the drive by right-clicking the
drive in Thunar and clicking eject.
- General comment on printing:
- At various times throughout the course you will be asked to provide
a printout with your lab submission; often times it may be a sample
packet capture. Please refrain from printing more than 1 or 2 pages of
any sample.
- Gaining root Privilege (Important!):
- Many of the tools used in this course require root privileges.
In general when you do need root privilege you have two options,
either execute a program as root or switch to user
root
.
Unless you are performing system administration functions, this second
option is dangerous and unnecessary as it gives you the ability (and
liability) to do damage. By default in this course you will be logged
on as user eee473
, and the Linux VM has been configured
such that you never need to be user root
. You will
receive specific instructions (using sudo command X
)
whenever you need to execute a command that requires root
privileges.
- Note:
- Consider why it is not a good idea to just switch to user
root
.
- Firstly, you have complete access to the file system and can
therefore easily (by accident) damage the configuration of the
operating system as well as its applications.
- Secondly, any program executed while you are root is run with
root
privilege. It should become obvious to
you in this course that this is not a good idea from a security
perspective.
Part 3 - Understanding the Lab Network Infrastructure:
Figure 1 - CNSL Network Set-up
- Referring to Figure 1 above, let's review the terminology that will be
used during the exercises and labs in this course.
- Team Network.
- We will refer to the network configuration established (by
you) within the VMware virtual environment as the "Team Network".
- Common Network.
- We will refer to the network configuration established within the
common lab infrastructure ("in the cage") as the "Common Network".
- Virtual Switches.
- There are two virtual switches within the Team Network:
- Internal Virtual Switch.
- The "Internal Virtual Switch" will be used to connect instances
of VMs to each other within the Team Network.
- External Virtual Switch.
- The "External Virtual Switch" will be used to connect instances
of the VMs to the common network (through the Patch Panel).
- Mapping Network Adapters to Virtual Switches
- Each VM is pre-configured with two network adapters / interfaces.
- On each VM we will use one network adapter/interface to connect to
the internal virtual switch and another to connect to the external
virtual switch.
- Prior to each exercise or lab, the network adapters / interfaces
within the Team Network must normally be configured. Follow the
steps below for each type of VM.
- Windows VM Network Adapter Configuration
- Return to the Windows VM
- View and set the Internal adapter settings:
- Select
start -> Control Panel -> Network
Connections
- Right-click on the adapter named Internal and
select
Enable
to enable this adapter
- Right-click again on the adapter and select
Status
.
- Then in the
General
tab, select Properties
-> Internet Protocol (TCP/IP) -> Properties
and
select "Use the following IP address:
"
- Set your IP address. Recall that the variable
x
is your host machine number that was recorded at the beginning
of this exercise.
- Set your sub-net mask.
- You do not have to worry about the Gateway or DNS settings
for this exercise.
- Select
OK
to apply these settings; be patient,
this could take time.
- View but do not set the External adapter settings:
- Right-click on
Local Area Connection
and Rename
the adapter to External
- Right-click again on the adapter and select
Status
.
View the Support
tab.
- The connection status is likely listed as Limited or no
connectivity.
- Do not change the settings at this time.
- Double-check your results from the command prompt:
- Open a Command Prompt (if you have forgotten how, go back to an
earlier step in the preamble).
- The program
ipconfig
can be used for displaying
and modifying network adapter settings.
- type
ipconfig /?
- Review the uses of this program
- type
ipconfig /all
- Confirm that the settings displayed for the network adapters
are as set in the previous steps.
- Linux VM Virtual Switch Configuration
- View and set the Internal interface settings:
- Open a Terminal.
- The program
ifconfig
can be used for displaying
and modifying network interface settings. Note the slight
difference in spelling from the similar application used by
Windows.
- Run
ifconfig
with the help switch -h
ifconfig -h
- Review the uses of this program
- Using
ifconfig
, list all interfaces:
- One of the listed interfaces should be named internal.
This interface should not have an IP assigned. The interface may
also be down, which you can tell because of the lacking "
UP
"
before "BROADCAST
" on the second line of the
listing.
- Set the Internal interface and bring it up:
sudo ifconfig internal 10.30.x.10 netmask
255.255.255.0 up
- View but do not set the External interface:
- Rerun
ifconfig -a
. Observe the total number of
interfaces listed.
- One is used for connecting to the Internal Virtual Switch, "
internal
"
(outlined above) and should now be set as per the instructions
above.
- One is the loopback interface, "
lo
"
- Record any other interface listed: ________. During the
course, this one will be referred to as the External interface
- Is it assigned an IP? ______
- Do not change the settings at this time.
- Perform a self-test of the Internal Virtual Switch
- From a Terminal in the Linux VM,
ping
the Windows
VM:
ping Windows_VM_IP
(recall the appropriate
Windows VM internal IP from above).
- Is there a connection? ____
- Cancel
ping
by typing Ctrl-c
- From the Command Prompt in the Windows VM,
ping
the
Linux VM across the Internal Virtual Switch:
ping Linux_VM_IP
(recall the appropriate
Linux VM IP from above).
- Is there a connection? ____
- There is no need to cancel, as Windows
ping
is
configured to only send 4 pings.
- When you have completed this step:
- Go to the Windows VM and disable the Internal Adapter.
- Right-click on the adapter named Internal and
select
Disable
to disable this adapter
- Go the the Linux VM and bring down the Internal interface
sudo ifconfig internal down
Part 4 - How to end your session:
The guidance above should help you master the effective use of the RMC
Computer Network Security Lab 4112 virtual lab environment. Until you become
familiar with these instructions, refer to
them at the beginning of each day's exercises and labs.
You must replace your divots! Always leave the lab in the same configuration
you found it; remember that graduate students and others are also using the
infrastructure.
VMs are represented as files in VMware; a running VM takes up lots of space,
so we must take care not to leave VMs running. It is also important to allow
the OS (Windows or Linux) to properly shut-down so that it can clean-up at
the end of a session. When you are finished in the lab, you must:
- Power Down the Windows VM.
- Select start
, then select Turn Off Computer
and finally select Turn
Off
.
- Power Down the Linux VM.
- Select the green gecko

->
Log Out -> Shut Down
. Alternately you can use the Log Out
dialogue in the lower right of the panel.
- You should now be back where you started, at the main welcome screen.
- Note that by correctly following the procedure above you are shutting
down the virtual machines and not the underlying host. This leaves the
host running for the next student to log in to their environment.
No report is necessary for this laboratory.