Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. And see here for current known issues.

New Member

Port Security

Can you setup port security to automatically learn MAC addresses on a switch? If so, how?

2 REPLIES

Re: Port Security

Re: Port Security

Can you setup port security to automatically learn MAC addresses on a switch? If so, how?

Hi ,

Dynamic port security is great but what about when you connect switches to routers or other devices that need to be secured in a way to prevent unauthorized device swapping in the network.


There are two ways to configure a sticky port. The first way being that you configure a static MAC address when configuring port-security on a specific interface. The next way which is more convenient is to configure a “Sticky” MAC address and leave the max MAC addresses to its default value of one. When port-security is configured this way, the first MAC address learned on the switch port will be automatically statically configured into the running-configuration as if you manually specified the MAC address

switchport port-security mac-address h.h.h – This command is executed in interface configuration mode and statically sets a MAC address that allows traffic with the source MAC to traverse the switch.

switchport port-security mac-address sticky – This command is executed in interface configuration mode and configures the port to dynamically learn the MAC address and automatically configure the MAC address as a static MAC address associated with the port.

Hope to Help !!

Remember to rate the helpful post

Ganesh.H

611
Views
0
Helpful
2
Replies