Using Port Security to lock on port to one MAC address

To ensure that only a particular mac address can plug into a port go under the port interface

interface fa 0/2

switchport mode access

switchport port-security

switchport port-security maximum 1

switchport port-security violation [shutdown | restrict | protect]

switchport port- security mac-address xxxxxxxxx

or

switchport port-security mac-address sticky