Record a switch configuration ACL records, the demand is to configure a Vlan to restrict access to other Vlan, as well as restricted Vlan can only access its > other VLAN specified IP after all, this is usually very little to configure a configuration of all kinds of look for documentation, is very inconvenient, after all, just a few
The commands are just a few! Not much to say, directly into the main topic.
Create ACLs and add rules
Switch>enableSwitch#Switch#configure terminalSwitch(config)#ip access-list extended deny55 # Create ACL extension deny55 groupSwitch(config-ext-nacl)#1 permit ip 10.30.55.0 0.0.0.255 host 10.30.51.35 # Allow 10.30.51.35 to access 10.30.55.0 network segmentSwitch(config-ext-nacl)#10 deny ip 10.30.55.0 0.0.0.255 10.30.51.0 0.0.0.255 # Deny access to 10.30.51.0 on the 10.30.55.0 network segmentSwitch(config-ext-nacl)#20 deny ip 10.30.55.0 0.0.0.255 10.30.52.0 0.0.0.255 # Deny access to 10.30.52.0 on the 10.30.55.0 network segmentSwitch(config-ext-nacl)#100 permit ip any any # Other IPs are allowed access by defaultSwitch(config-ext-nacl)#show this # To view the current ACL deny55 group rule, configure the attention sequence numberBuilding configuration...! 1 permit ip 10.30.55.0 0.0.0.255 host 10.30.51.19 10 deny ip 10.30.55.0 0.0.0.255 10.30.51.0 0.0.0.255 20 deny ip 10.30.55.0 0.0.0.255 10.30.52.0 0.0.0.255 100 permit ip any any!endSwitch(config-ext-nacl)#exitThe created ACL is referenced to the specified Vlan (it can also be applied to the device interface).
Switch>enableSwitch#Switch#configure terminalSwitch(config)#interface vlaN 15 # Enter VLAN 15 configurationSwitch(config-if-VLAN 15)#ip access-group deny55 in # Apply deny55 to vlan 15.Switch(config-if-VLAN 15)#show thisBuilding configuration...! ip access-group deny55 in ip address 10.30.55.254 255.255.255.0!endSwitch(config-if-VLAN 15)#endSee if the ACL rule is correct and save
Switch#show access-listsip access-list extended deny55 # view the rules that have been added to an ACL 1 permit ip 10.30.55.0 0.0.0.255 host 10.30.51.35 10 deny ip 10.30.55.0 0.0.0.255 10.30.51.0 0.0.0.255 20 deny ip 10.30.55.0 0.0.0.255 10.30.52.0 0.0.0.255 30 deny ip 10.30.55.0 0.0.0.255 10.30.53.0 0.0.0.255 40 deny ip 10.30.55.0 0.0.0.255 10.30.54.0 0.0.0.255 50 deny ip 10.30.55.0 0.0.0.255 10.30.56.0 0.0.0.255 60 deny ip 10.30.55.0 0.0.0.255 10.30.58.0 0.0.0.255 70 permit ip any any (2 packets filtered)Switch#write # Saving the Current Configurationend here
Switch Configuration ACL Access Control
https://huoshen.pages.dev/p/c014c0bb/