Home > Articles > Cisco Network Technology > General Networking > VLAN Access Control Lists

VLAN Access Control Lists

Article Description

The latest generation of Cisco switching engines open up security and QoS, presenting new concepts for the campus network. Learn the steps to be taken to change with the times.

Modifying VACLs

After implementing the policy and having it run in our network, some problems come to our attention that need modification. Note that our second statement that was supposed to deny IP traffic within the 172.16.101.0 subnet has an invalid destination network address (172.16.1.0). This must be corrected. Also, it happens that there is another router on this VLAN and our configured gateway keeps sending ICMP redirects to the clients to use this router for certain networks, but due to the entry in the list that stops all other ICMP traffic, these redirects are being blocked. After applying the list, we learn that one of the minor applications running on server 172.16.101.44 regularly sends out broadcasts on UDP port 6108 to determine whether or not clients are active. If these clients don't respond back on UDP port 18888, their sessions with the server times out. It is determined that the following adjustments need to be made to the access policy:

Cat6K (enable) set security acl ip accesspolicy deny ip 172.16.101.0 0.0.0.255 
172.16.101.0 0.0.0.255
accesspolicy editbuffer modified. Use 'commit' command to apply changes.
Cat6K (enable) set security acl ip accesspolicy permit icmp host 172.16.101.1 
any host-redirect
accesspolicy editbuffer modified. Use 'commit' command to apply changes.
Cat6K (enable) set security acl ip accesspolicy permit udp host 172.16.101.44 
host 255.255.255.255 eq 6108
accesspolicy editbuffer modified. Use 'commit' command to apply changes.
Cat6K (enable) set security acl ip accesspolicy permit udp any host 
172.16.101.44 eq 18888
accesspolicy editbuffer modified. Use 'commit' command to apply changes.

At this point, the changes have been written to the editbuffer, but not committed to the TCAM. If we view the VACL, we note no changes. However, if we view the editbuffer, the changes are clear:

Cat6K (enable) show security acl info accesspolicy
set security acl ip accesspolicy
---------------------------------------------------
1. permit icmp any host 172.16.101.1 
2. deny ip 172.16.101.0 0.0.0.255 172.16.1.0 0.0.0.255 
3. deny icmp any any echo 
4. permit ip any any 

Cat6K (enable) show security acl info accesspolicy editbuffer                       
set security acl ip accesspolicy
---------------------------------------------------
1. permit icmp any host 172.16.101.1
2. deny ip 172.16.101.0 0.0.0.255 172.16.1.0 0.0.0.255
3. deny icmp any any echo
4. permit ip any any
5. deny ip 172.16.101.0 0.0.0.255 172.16.101.0 0.0.0.255
6. permit icmp host 172.16.101.1 any host-redirect
7. permit udp host 172.16.101.44 host 255.255.255.255 eq 6108
8. permit udp any host 172.16.101.44 eq 18888
ACL accesspolicy Status: Not Committed

The problem is that we can't add these to the bottom of the list because they would have no effect after the permit ip any any statement. So when we make these changes, a keyword before will be used at the end of the set command followed by the index number in the editbuffer of the item that we want to place them before. For the statement that changes the address for entry number 2, we will use the keyword modify to change that entry. Before we can add the statements correctly, however, we need to remove all the changes to the editbuffer. Because the editbuffer has not been committed, we can use the rollback command to change the editbuffer back to the most recent committed state.

Cat6K (enable) rollback security acl accesspolicy
Editbuffer for 'accesspolicy' rolled back to last commit state.

Cat6K (enable) show security acl info accesspolicy editbuffer
set security acl ip accesspolicy
---------------------------------------------------
1. permit icmp any host 172.16.101.1 
2. deny ip 172.16.101.0 0.0.0.255 172.16.1.0 0.0.0.255 
3. deny icmp any any echo 
4. permit ip any any 
ACL accesspolicy Status: Committed

Now we need to re-enter the commands with the appropriate keywords. But we also need to know where to place the entries in respect with the current list, so we will view the current list with the show security acl info command:

Cat6K (enable) show security acl info accesspolicy
set security acl ip accesspolicy
---------------------------------------------------
1. permit icmp any host 172.16.101.1 
2. deny ip 172.16.101.0 0.0.0.255 172.16.1.0 0.0.0.255 
3. deny icmp any any echo 
4. permit ip any any 

Note that we need to modify entry number 2. Place the ICMP permit statement in before entry number 3 and the remaining two statements need to be placed in before entry number 2. As the first one is placed in before number 2, it will become entry 2. This means that all the original statements will move down one in the index; what was entry 2 is now entry 3. The next statement will now be placed in the list before what is now entry number 3:

Cat6K (enable) set sec acl ip accesspolicy deny ip 172.16.101.0 0.0.0.255 
172.16.101.0 0.0.0.255 modify 2
accesspolicy editbuffer modified. Use 'commit' command to apply changes.
Cat6K (enable) set security acl ip accesspolicy permit icmp host 172.16.101.1 
any host-redirect before 3
accesspolicy editbuffer modified. Use 'commit' command to apply changes.
Cat6K (enable) set security acl ip accesspolicy permit udp host 172.16.101.44 
host 255.255.255.255 eq 6108 before 2
accesspolicy editbuffer modified. Use 'commit' command to apply changes.
Cat6K (enable) set security acl ip accesspolicy permit udp any host 
172.16.101.44 eq 18888 before 3
accesspolicy editbuffer modified. Use 'commit' command to apply changes.

Cat6K (enable) show security acl info accesspolicy editbuffer
set security acl ip accesspolicy
---------------------------------------------------
1. permit icmp any host 172.16.101.1 
2. permit udp host 172.16.101.44 host 255.255.255.255 eq 6108 
3. permit udp any host 172.16.101.44 eq 18888 
4. deny ip 172.16.101.0 0.0.0.255 172.16.101.0 0.0.0.255 
5. permit icmp host 172.16.101.1 any host-redirect 
6. deny icmp any any echo 
7. permit ip any any 
ACL accesspolicy Status: Not Committed

Now one of the advanced features of the VACL is that these changes are not being applied to the active list. If you check the active ACL, none of these changes are in effect.

Cat6K (enable) show security acl info accesspolicy 
set security acl ip accesspolicy
---------------------------------------------------
1. permit icmp any host 172.16.101.1 
2. deny ip 172.16.101.0 0.0.0.255 172.16.1.0 0.0.0.255 
3. deny icmp any any echo 
4. permit ip any any 

You would have to commit the changes before it affected the traffic flow. At this point, you would use the show security acl info accesspolicy editbuffer to verify the changes. If you want to eliminate all the changes, you could issue a rollback security acl accesspolicy command and clear all the changes in the editbuffer, or you could clear individual entries by using the clear security acl accesspolicy <edditbuffer_index> command. After you are satisfied with the changes, commit them by using the commit security acl accesspolicy command. This adds the entries to the active list and changes the flow of traffic accordingly. Verify these changes with the show security acl info accesspolicy command:

Cat6K (enable) commit security acl accesspolicy
ACL commit in progress.

ACL 'accesspolicy' successfully committed.
Cat6K (enable) show security acl info accesspolicy
set security acl ip accesspolicy
---------------------------------------------------
1. permit icmp any host 172.16.101.1 
2. permit udp host 172.16.101.44 host 255.255.255.255 eq 6108 
3. permit udp any host 172.16.101.44 eq 18888 
4. deny ip 172.16.101.0 0.0.0.255 172.16.101.0 0.0.0.255 
5. permit icmp host 172.16.101.1 any host-redirect 
6. deny icmp any any echo 
7. permit ip any any 
6. Removing VACLs | Next Section Previous Section