Leaflet

29
OL-11615-01
For more information on how to configure Port Security on Catalyst 6500 running Catalyst OS, refer to
the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/lan/cat6000/sw_8_5/confg_gd/sec_port.htm
For more information on how to configure Port Security on Catalyst 4500 running Catalyst OS, refer to
the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/lan/cat4000/8_3/configur/sec_port.htm
Configuring Port Security in Cisco IOS
To configure Port Security on Cisco IOS, perform the following steps:
Step 1 Enable port security on the desired ports using the switchport port-security interface command:
Switch(config)# interface
type slot/port
Switch(config-if)# switchport port-security
Step 2 Configuring the Port Security violation mode on the port using the switchport port-security violation
interface command. By default the violation mode is set to shutdown:
Switch(config-if)# switchport port-security violation {protect | restrict | shutdown}
Step 3 Add the MAC addresses to the list of secure addresses using the switchport port-security mac-address
interface command:
Switch(config-if)# switchport port-security mac-address [sticky] mac_address [vlan
vlan_ID]
Step 4 Set the maximum number of secure MAC addresses using the switchport port-security maximum
interface command. By default the number is set to 1:
Switch(config-if)# switchport port-security maximum
number_of_addresses
vlan {
vlan_ID
|
vlan_range}
In this example interface GigabitEthernet2/24 is configured as a secure port, a static secure MAC address
entry is defined for 0090.2b03.3408, and the port is configured to accept up to five dynamically learned
MAC addresses. The port is configured in the protect security violation mode.
Switch(config)# interface GigabitEthernet2/24
Switch(config-if)# switchport
Switch(config-if)# switchport mode access
Switch(config-if)# switchport port-security
Switch(config-if)# switchport port-security violation protect
Switch(config-if)# switchport port-security maximum 5
Switch(config-if)# switchport port-security mac-address 0090.2b03.3408
Switch(config-if)# end
For more information on how to configure Port Security on Catalyst 6500 running Cisco IOS, refer to
the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/lan/cat6000/122sx/swcg/port_sec.htm
For more information on how to configure Port Security on Catalyst 4500 running Cisco IOS, refer to
the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/lan/cat4000/12_2_31s/conf/port_sec.htm