Extended ACLs
IP and TCP Header
IP Header
Misc Header Fields▪ 9 bytes
- 2 bytes
tcp or udp keyword
-
- can optionally reference the source and/or destination portequal, not equal, less than, greater than, and for a range of port numbers
- can use port numbers or keywords for some well-known application ports
positions of the source and destination port fields in the access-list command and these port
number keywords.access-list 101 permit (protocol) Source_IP (source port) dest_IP (dest port)
Protocol– tcpudp-
- eq ne
- lt_
-
-
- lt_gt_
- range_
-
- eq ne
-
- lt_gt_
- range_
-
eq 21 is in the destination port position
Apps and Port number shortcuts for ACL Commands
20 21 ftpftp-data
22 -
23 25 telnetsmtp
53 67 domainbootps (dhcp server)
68 69 bootpc (dhcp clienttftp )
80 www
110 161 pop3snmp
443 514 - -
16,384 -32,767 (RTP/ Voice/ Video) -
Extended IP ACL Configuration -
enable the ACL using the sameip access-groupcommand used with standard ACLs.
- saves some bandwidth.
-
Place extended ACLs as close as possible to the source of the packets that will be filtered.
-
ACL numbers - 100 – 199 and 2000– 2699
Extended IP Access Lists: Example 1
#(int) ip access-group 101 in
- Easier to remember
-
- Uses ACL subcommands instead of global config commandsediting features allow deleting individual lines and inserting new ones
Config
#(ACLmode) permit 1.1.1.1
#(ACLmode) permit 2.2.2.2#(ACLmode) permit 3.3.3.3
#(ACLmode) deny ip 10.1.2.0 0.0.0.255 10.2.3.0 0.0.0.255
- Uses ACL subcommands instead of global config commandsediting features allow deleting individual lines and inserting new ones
- deleting a single entry from the ACL.
- delete and add new lines to the ACL from within ACL configuration mode
Named ACLs and ACL Editing
-
ACL sequence number is added to each ACL permit or deny statement,
-
numbers represent the sequence of statements in the ACLNumbered ACLs can use a configuration style like named ACLs, as well as the traditional
-
style, for the same ACL; the new style is required to perform advanced ACL editing.
-
Deleting single lines:- delete an ACE with a no sequence-number subcommand.
New ACEs can be configured with a sequence number before the deny or permit
command, dictating the location of the statement within the ACL. -
Inserting new lines: -
-
Automatic sequence numbering: - sequence numbers are added to ACEs automatically
Show ip access- Shows access list 24 and sequence numbers with each entry-lists 24
#(ACLmode) no 20
-
- enters this new ace as sequence #5Places the sequence number in the list in order
-
Editing ACLs Using Sequence Numbers (named and numbered (not the global numbered way)
-
-
Numbered ACL Configuration Versus Named ACL Configuration
- Place more specific statements early in the ACL.
- By doing so, you avoid issues with the ACL during an interim state
- Disable an ACL from its interfacemaking changes to the ACL. (using the no ip access-group interface subcommand)before
ACL Implementation Considerations
Mitigating Security Issues with ACLs
Security threats that can be mitigated with ACLs
- IP address spoofing, inbound
- -IP address spoofing, outboundDoS TCP SYN attacks, blocking external attacks
- Dos TCP SYN attacks, using TCP Intercept
- -DoS smurf attacksDenying/filtering ICMP messages, inbound
- -Denying/filtering ICCMP messages, outboundDenying/filtering Traceroute
- -Deny any source addresses from your internal networks Deny any local host addresses (127.0.0.0/8)
- -Deny any reserved private addresses (RFC 1918)Deny any addresses in the IP multicast address range (224.0.0.0/4)
Controlling VTY (Telnet/ SSH) Access
- Create a standard IP access list that permits only the host or hosts you want to be able to telnet into the routers.
- Apply the access list to the VTY line with the access-class in command.
(g) # access-list 50 permit host 172.16.10.3
(g) # line vty 0 4(int) # access-class 50 in
Monitoring Access Lists
show access-list
shows access lists, parameters, statistics, etc.
show access-list 110
Shows info for access list 110
show ip access-list
shows IP access lists on the router
show ip interface
Shows which interfaces have access lists set on them.
show running-config
Shows ACLs and what interfaces that have them.