Port security is a Layer 2 security feature that restricts the number of devices connecting to a network switch port. It helps prevent unauthorized devices, such as an unmanaged switch, from being connected to the network. How Port Security Works: Limits the number of MAC addresses that can connect to a port. Can shut down or restrict the port if an unauthorized device is detected. Prevents users from plugging in unauthorized networking equipment (e.g., unmanaged switches, hubs).