Ccna Acl Lab: School of Information Studies Syracuse University Created by 4/22/2008 By: James Benninger Used in CCNA
Ccna Acl Lab: School of Information Studies Syracuse University Created by 4/22/2008 By: James Benninger Used in CCNA
Ccna Acl Lab: School of Information Studies Syracuse University Created by 4/22/2008 By: James Benninger Used in CCNA
Lab Overview
This lab is designed to provide students with familiarity and experience in working with access control
lists. The lab will provide an overview on how to use access lists to secure a network. The lab will also
give you an understanding of the different kinds of access lists.
Students will be able to gain access to the switch, do basic switch configuration, enter a series of ACE’s
(access control entries), and also configure different kinds of ACL’s (access control lists).
This lab is based on Cisco Catalyst 3560-24PS switches, which provides a combination of twenty four
1Gbs ports and four 10gps uplink ports.
Lab Prerequisites
Before attempting this lab, students should have the following knowledge and experience:
Intermediate-level experience working with the Microsoft Windows operating system and
associated application, such as the HyperTerminal.
General knowledge of the OSI model, the principles of packet switching and layered
communication.
Familiarity with the basic design and operation of Ethernet networks, including a general
understanding of Ethernet frame format, addressing, and cabling systems.
Working knowledge of TCP/IP including a general understanding of IP addressing and how
TCP/IP works on Ethernet networks.
Working familiarity with the Windows TCP/IP Ping utility.
2
Expected Duration
Approximately 1-1.5 hours
b. There are also two types of distinct ACL’s that you will be configuring in the lab. These two
types are:
1. Standard
Standard ACL’s are given a number between 1 and 99 when being
configured. These access lists cannot filter by protocol. The permit and deny
statements used to configure these access lists will deny everything. These
can be useful, though you can run into problems if you want to do
something such as allow ICMP requests to go through, but you want to
block telnet to a certain host.
2. Extended
Extended ACL’s use
3
c. The third thing you should keep in mind when configuring access –lists is that the last line of
every ACL should be a permit ip any any. This is because by default there is an implicit deny
ip any any in every access list configuration.
Note: For the purposes of this section, when entering commands X should be replaced by the
VLAN number located on the sheet of paper pasted on your desk.
a. Before configuring the access control lists we must do the basic configuration of the switch
1. To access the switch via the console line, please refer to appendix A.
2. Enter the following commands into the CLI (command line interface) of the switch
Switch> enable
Password: ITELLadmin
Switch# configure terminal
Switch(config)# hostname <your Department> (e.g. Technical_Support)
3. Now we need to configure the PC’s of your department onto separate VLAN’s
This needs to be done so that we can filter the traffic between yours PC’s
To do this enter the following commands in config mode:
4
Switch(config-if)# Ctrl-Z
Switch# sh vlan
5. The output should look similar to the following (pay close attention to the circled
information):
6. Next we need to assign an IP Address to the VLAN you have created. This is because
the VLAN will be used as the default gateway for your host PC later on in the lab.
7. To assign the IP to the VLAN type the following command in config mode:
Switch(config)#int vlan X
Switch(config-if)#no shutdown
Switch(config-if)#ip address 192.168.X.1 255.255.255.0
Switch(config-if)#Ctrl-Z
5
8. To verify that you have correctly configured everything type in the show
running-config command while in privileged exec mode.
3. Configuring RIP:
a. You now need to configure the routing protocol RIP. You will configure it now and will
be using it later on in the lab to ping from the 192.168.1.0 network to the 192.168.X.0
network you have configured.
1. The next thing that you are going to do is configure a routing protocol on your
switch. To do this we are going to enable RIP version two. To do this type in the
following commands from config mode:
2. To verify that you have correctly configured rip, exit to privileged-exec mode and
type show ip route. You should see RIP statements in the routing table. If you do
not, go back in the lab and make sure that you have properly configured RIP.
6
2. Note down the ip address and default gateway address here as you will need to use
them in later sections in the lab
IP Address: ______________________
Default Gateway Address: ______________________
Ping <The default gateway address you noted down earlier in the lab>
Example: Ping 192.168.9.1
3. If you can successfully ping your default gateway, then the next step is to try and
ping the other host PC in your department.
4. To do this type in the following command:
5. You should notice that the ping was successful. If it was not, then you should go
back in the lab and make sure that you have correctly configured your PC, RIP, and
the switch.
7
6. Configuring A Standard ACL
a. In configuring the basic access list you will be making an access list statement to
deny traffic from the 192.168.1.0 network. After making the statement you will
apply it to port gi0/15. Notice when configuring your access list that you are
using a number between 1 and 99.
Write down the access list number you chose here so that you have it for the next step
in the lab: _______
2. You will now apply this access list to the gigabit Ethernet 15 port. To do this enter
the following commands:
b. Next you need to check to make sure that you have correctly configured and assigned
your access-list. Since this is a standard ACL (refer to section 1), when you typed in the
deny statement ICMP (PING) will automatically be denied.
8
3. To test this you and your partner should try to ping each other
If you have forgotten how to ping refer to section 5.4.
4. You should notice that the pings are not successful. Your output should look similar
to the following:
Note: If your output does not match this, then you should go back and check to make sure
that you have properly configured and applied your ACL.
c. In order to configure your next access-list you will take the current access-list off of the
port. If you wanted to, you could leave it on the port and add more, but you have to
keep in mind that both of the ACL’s will be working on the port.
6. To verify that you have properly removed the access-list type in the following
commands. You should still see the access-list in the configuration, but you should
no longer see the access-list associated with port 15.
Switch(config-if)#<Ctrl Z>
Switch#show running-configuration
9
7. You have just taken the ACL off of the port. You have not removed the ACL from the
switch. This is good practice because if you want to use this ACL on a different port
or if you want to redo it on the port all you have to do is put it back on the port. This
prevents you from having to recreate the ACL every time you want to use it. You can
view your created ACL’s in two different ways. To view your configured ACL enter
the following commands from privileged exec mode.
Switch# Show run
Or
Switch# Show access-list
Switch(config)#access-list (any # between 100 and 199) deny icmp host (PC1’s
ip address) any host-unknown
2. To verify that you have correctly configured your access list exit to
privileged-exec mode and enter the show access-list command. The output
should look similar to the following:
10
3. Next you need to apply the ACL to a port. For the purposes of this section
you should put the ACL on the port that PC1 is attached to. This is interface
gi0/15. To do this type the following commands from config mode:
4. To test this you and your partner should try to ping each other. If you have
forgotten how to ping refer to section 4.4.
6. Before moving onto the next section you should remove the ACL from the
port by typing in the following commands from config mode:
8. Simulation Test
a. In this section you will be configuring an access-list that would be similar to what you
can expect to see on the CCNA exam. The ACL’s in the exam simulation will generally
require a few statements in order to get the right affects.
For this simulation our goal is to block all traffic from the 192.168.1.0 network
to the 192.168.X.0 network. However, we want to allow PC1 from the MIS department
which should be on the 192.168.1.0 network.
1. The first step is to create an ACL that permits PC1 to go to a PC2 in your
department. When entering this command, please be sure to enter a different
number then the one you have used in your previous ACL’s. To create the ACL
go to config mode and type in the following command:
11
2. The next statement needed will be the statement that will deny any other
traffic from the 192.168.1.0 network to the 192.168.X.0 network. To do this
type in the following command from config mode:
3. The next step is to permit all other traffic. This allows transit traffic to go
across the network. This should be the last line of all access lists configured in a
real world environment. To do this type in the following command:
4. Now that you have properly configured your ACL you must add it to a port.
To do this enter the following commands:
5. To test this you and your partner should try to ping each other
6. You should notice that the pings were successful. If they were not successful
please look back at your statements and make sure that they have been
properly entered.
7. The next step is to go to another department in the room that has been
properly configured. Try to ping PC2 of your department from PC1 of their
department. You should notice that the ping is unsuccessful. This is due to the
fact that you have denied all traffic from the 192.168.1.0 network to the
192.168.X.0 network.
9. Housekeeping
a. Once the lab exercises are completed, please return your configuration to the original
state i.e to restore the switch to its factory defaults.
1. From the command line, go to privileged exec mode and type in the
following command to bring the switch back to factory defaults:
Switch#erase nvram
12
Appendix A:Configuring Hyperterminal
1. Once you have connected the null modem serial cable to the COM 1 serial port on your PC, open the
Hyperterminal program by clicking on Start Run and entering c:\program files\windows
NT\hypertrm.exe
2. When you click OK, the ‘New Connection – Hyperterminal’ window opens up.
4. The ‘Connect to’ Dialog box opens. Make sure you connect using COM1. Click OK.
5. The Hyperterminal software on the PC must be configured with the following settings:
13
• 9600 baud
• 8 data bits
• No parity
• 1 stop bit
• XON/XOFF
The ‘COM 1’ Properties dialog box opens. Make sure the settings are as follows:
6. Click OK and then hit [return] a few times and you should see the prompt login:
Note: On PCs where Hyperterminal has never been opened before, you will first See the ‘Location
Information’ dialog box when you open the program. In this case, enter 315 in the area code field, then
click OK, and in the ‘Modem and Phone Information’ dialog box click OK again. This will open the dialog
box as seen in Step 1.
14
Appendix B:To change static IP of workstation
Note: Make sure you remember to configure both the IP addresses of PC 1 and 2 before you
proceed.
1. From the desktop, right-click on the My Network Places icon and select Properties
option.
2. Right-click on LAN connection and select Properties menu option.
3. Go back to the LAN Properties window. Note the various network services available in
theGeneral tab window
4. Double-click on Internet Protocol (TCP/IP).
PC1- In the box next, where it says IP address, enter the first available IP address
from the Flat IP Pool on your desk
PC2- In the box next, where it says IP address, enter 192.168.X.100 (X should be
replaced with the VLAN number pasted on your)
15
7. Next you have to specify the Subnet mask. In Subnet mask you should have:
“255.255.255.0”.
PC1- In the box next to Default Gateway enter the Switch IP address from the
label on your desk.
PC2- In the box next to Default Gateway enter 192.168.X.1 X should be replaced
with the VLAN number pasted on your)
9. Click OK in the TCP/IP properties window and then click OK in the Local Area
Connection window.
10. Verify that your IP address has changed by running the ipconfig command from the
command line.
16
LAB QUESTIONS
Name Date
Course Professor
2. Fill in the following blanks with the information you typed in: (Section 4)
a) IP Address: _______________________________
17
6. Why was the ping from another department’s PC1 to your departments PC2
unsuccessful? (Section 8)
18