1-7
z If both the limit on the number of MAC address authentication users and the limit on the number of
users configured in the port security function are configured for a port, the smaller value of the two
configured limits is adopted as the maximum number of MAC address authentication users allowed
to access this port. Refer to the Port Security manual for the description on the port security
function.
z You cannot configure the maximum number of MAC address authentication users for a port if any
user connected to this port is online.
Displaying and Maintaining MAC Authentication
To do… Use the command… Remarks
Display global or on-port
information about MAC
authentication
display mac-authentication
[ interface interface-list ] Available in any view
Clear the statistics of global or
on-port MAC authentication
reset mac-authentication statistics
[ interface interface-type
interface-number ] Available in user view
MAC Authentication Configuration Example
Network requirements
As illustrated in Figure 1-1, a supplicant is connected to Switch through port GigabitEthernet 1/0/2.
z MAC authentication is required on port GigabitEthernet 1/0/2 to control user access to the Internet.
z All users belong to domain aabbcc.net. The authentication is performed locally and the MAC
address of the PC (00-0d-88-f6-44-c1) is used as both the username and password.
Figure 1-1 Network diagram for MAC authentication configuration
IP network
PC
MAC: 00-0d-88 -f 6- 44-c1 Switch
GE 1/0/2
Configuration Procedure
# Enable MAC authentication on port GigabitEthernet 1/0/2.
<device> system-view
[device] mac-authentication interface GigabitEthernet 1/0/2
# Specify to use the user MAC address as both the username and password for MAC authentication,
and specify the MAC address format as hyphened lowercase MAC address.
[device] mac-authentication authmode usernameasmacaddress usernameformat with-hyphen
lowercase