0% found this document useful (0 votes)
33 views26 pages

Configuring and Troubleshooting Acls: Access Control Lists

ICND210S06L02
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPS, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
33 views26 pages

Configuring and Troubleshooting Acls: Access Control Lists

ICND210S06L02
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPS, PDF, TXT or read online on Scribd

2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.

06-1
Access Control Lists
Configuring and
Troubleshooting
ACLs
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-2
Testing Packets with
Numbered Standard IPv4 ACLs
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-3
Activates the list on an interface.
Sets inbound or outbound testing.
no ip access-group access-list-number {in | out} removes the ACL from the interface.
ip access-group access-list-number {in | out}
Uses 1 to 99 for the access-list-number.
The first entry is assigned a sequence number of 10, and successive entries
are incremented by 10.
Default wildcard mask is [Link] (only standard ACL).
no access-list access-list-number removes the entire ACL.
remark lets you add a description to the ACL.
access-list access-list-number
{permit | deny | remark} source [mask]
RouterX(config)#
RouterX(config-if)#
Numbered Standard IPv4 ACL
Configuration
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-4
Permit my network only
Numbered Standard IPv4 ACL
Example 1
RouterX(config)# access-list 1 permit [Link] [Link]
(implicit deny all - not visible in the list)
(access-list 1 deny [Link] [Link])

RouterX(config)# interface ethernet 0
RouterX(config-if)# ip access-group 1 out
RouterX(config)# interface ethernet 1
RouterX(config-if)# ip access-group 1 out
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-5
Deny a specific host
Numbered Standard IPv4 ACL
Example 2
RouterX(config)# access-list 1 deny [Link] [Link]
RouterX(config)# access-list 1 permit [Link] [Link]
(implicit deny all)
(access-list 1 deny [Link] [Link])

RouterX(config)# interface ethernet 0
RouterX(config-if)# ip access-group 1 out
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-6
Deny a specific subnet
Numbered Standard IPv4 ACL
Example 3
RouterX(config)# access-list 1 deny [Link] [Link]
RouterX(config)# access-list 1 permit any
(implicit deny all)
(access-list 1 deny [Link] [Link])

RouterX(config)# interface ethernet 0
RouterX(config-if)# ip access-group 1 out
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-7
Permits only hosts in network [Link] [Link] to connect
to the router vty lines
access-list 12 permit [Link] [Link]
(implicit deny any)
!
line vty 0 4
access-class 12 in
Example:
access-class access-list-number {in | out}
Restricts incoming or outgoing connections between a particular
vty and the addresses in an ACL
RouterX(config-line)#
Standard ACLs to Control vty Access
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-8
Testing Packets with
Numbered Extended IPv4 ACLs
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-9
ip access-group access-list-number {in | out}
Activates the extended list on an interface
Sets parameters for this list entry
access-list access-list-number {permit | deny}
protocol source source-wildcard [operator port]
destination destination-wildcard [operator port]
[established] [log]
RouterX(config)#
RouterX(config-if)#
Numbered Extended IPv4 ACL
Configuration
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-10
Numbered Extended IPv4 ACL
Example 1
RouterX(config)# access-list 101 deny tcp [Link] [Link] [Link] [Link] eq 21
RouterX(config)# access-list 101 deny tcp [Link] [Link] [Link] [Link] eq 20
RouterX(config)# access-list 101 permit ip any any
(implicit deny all)
(access-list 101 deny ip [Link] [Link] [Link] [Link])

RouterX(config)# interface ethernet 0
RouterX(config-if)# ip access-group 101 out
Deny FTP traffic from subnet [Link] to subnet [Link] out E0
Permit all other traffic
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-11
Numbered Extended IPv4 ACL
Example 2
RouterX(config)# access-list 101 deny tcp [Link] [Link] any eq 23
RouterX(config)# access-list 101 permit ip any any
(implicit deny all)

RouterX(config)# interface ethernet 0
RouterX(config-if)# ip access-group 101 out
Deny only Telnet traffic from subnet [Link] out E0
Permit all other traffic
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-12
ip access-list {standard | extended} name
[sequence-number] {permit | deny} {ip access list test conditions}
{permit | deny} {ip access list test conditions}
ip access-group name {in | out}
Named IP ACL Configuration
Alphanumeric name string must be unique
If not configured, sequence numbers are generated automatically starting at 10 and
incrementing by 10
no sequence number removes the specific test from the named ACL
Activates the named IP ACL on an interface
RouterX(config {std- | ext-}nacl)#
RouterX(config-if)#
RouterX(config)#
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-13
Deny a specific host
Named Standard IPv4 ACL Example
RouterX(config)#ip access-list standard troublemaker
RouterX(config-std-nacl)#deny host [Link]
RouterX(config-std-nacl)#permit [Link] [Link]
RouterX(config-std-nacl)#interface e0
RouterX(config-if)#ip access-group troublemaker out
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-14
Deny Telnet from a specific subnet
Named Extended IPv4 ACL Example
RouterX(config)#ip access-list extended badgroup
RouterX(config-ext-nacl)#deny tcp [Link] [Link] any eq 23
RouterX(config-ext-nacl)#permit ip any any
RouterX(config-ext-nacl)#interface e0
RouterX(config-if)#ip access-group badgroup out
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-15
Commenting ACL Statements
access-list access-list-number remark remark
ip access-list {standard|extended} name
Creates a named ACL comment
Creates a numbered ACL comment
RouterX(config {std- | ext-}nacl)#
RouterX(config)#
remark remark
RouterX(config)#
Creates a named ACL
Or
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-16
Monitoring ACL Statements
RouterX# show access-lists {access-list number|name}
RouterX# show access-lists
Standard IP access list SALES
10 deny [Link], wildcard bits [Link]
20 permit [Link]
30 permit [Link]
40 permit [Link]
Extended IP access list ENG
10 permit tcp host [Link] any eq telnet (25 matches)
20 permit tcp host [Link] any eq ftp
30 permit tcp host [Link] any eq ftp-data
Displays all access lists
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-17
Verifying ACLs
RouterX# show ip interfaces e0
Ethernet0 is up, line protocol is up
Internet address is [Link]/24
Broadcast address is [Link]
Address determined by setup command
MTU is 1500 bytes
Helper address is not set
Directed broadcast forwarding is disabled
Outgoing access list is not set
Inbound access list is 1
Proxy ARP is enabled
Security level is default
Split horizon is enabled
ICMP redirects are always sent
ICMP unreachables are always sent
ICMP mask replies are never sent
IP fast switching is enabled
IP fast switching on the same interface is disabled
IP Feature Fast switching turbo vector
IP multicast fast switching is enabled
IP multicast distributed fast switching is disabled
<text ommitted>
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-18
Troubleshooting Common ACL Errors
Error 1: Host [Link] has no connectivity with [Link].
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-19
Error 2: The [Link] network cannot use TFTP to connect to
[Link].
Troubleshooting Common ACL Errors
(Cont.)
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-20
Error 3: [Link] network can use Telnet to connect to [Link],
but this connection should not be allowed.
Troubleshooting Common ACL Errors
(Cont.)
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-21
Error 4: Host [Link] can use Telnet to connect to [Link],
but this connection should not be allowed.
Troubleshooting Common ACL Errors
(Cont.)
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-22
Error 5: Host [Link] can use Telnet to connect to [Link],
but this connection should not be allowed.
A B
Troubleshooting Common ACL Errors
(Cont.)
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-23
Error 6: Host [Link] can use Telnet to connect into router B, but
this connection should not be allowed.
B A
Troubleshooting Common ACL Errors
(Cont.)
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-24
Visual Objective 6-1: Implementing
and Troubleshooting ACLs
WG Router s0/0/0 Router fa0/0 Switch

A [Link] [Link] [Link]
B [Link] [Link] [Link]
C [Link] [Link] [Link]
D [Link] [Link] [Link]
E [Link] [Link] [Link]
F [Link] [Link] [Link]
G [Link] [Link] [Link]
H [Link] [Link] [Link]
SwitchH
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-25
Summary
Standard IPv4 ACLs allow you to filter based on source IP
address.
Extended ACLs allow you to filter based on source IP address,
destination IP address, protocol, and port number.
Named ACLs allow you to delete individual statements from
an ACL.
You can use the show access-lists and show ip interface
commands to troubleshoot common ACL configuration errors.
2007 Cisco Systems, Inc. All rights reserved. ICND2 v1.06-26

You might also like