Dynamic ARP Inspection (DAI) is a security feature that protects against ARP spoofing and other attacks by validating ARP packets before they are forwarded. Here’s how you can configure DAI on Cisco switches:
- Access the Command Line Interface (CLI):
Connect to your Cisco switch via console cable or SSH. - Enter Privileged Exec Mode:
Once connected, enter privileged exec mode by typing:
enableProvide the enable password if required.
- Enter Global Configuration Mode:
To configure DAI, enter global configuration mode:
configure terminalThis command allows you to make changes to the switch’s settings.
- Enable DAI on the Switch:
Use the following command to enable DAI globally:
ip arp inspection vlan <vlan_list>Replace with the list of VLANs you want to enable DAI on (e.g., 10,20,30).
For example:
ip arp inspection vlan 10,20,30- Enable DAI on Specific Interfaces:
You can enable DAI on specific interfaces. Enter interface configuration mode for each interface:
interface <interface_type> <interface_number>For example:
interface GigabitEthernet0/1Then, enable DAI:
ip arp inspection trustThis command marks the interface as trusted, meaning it allows ARP packets without validation.
- (Optional) Configure ARP Rate Limiting:
You can set a limit on the number of ARP requests and responses allowed per second on an interface. This can help prevent ARP flooding attacks.
ip arp inspection limit rate <number>Replace with the desired limit (e.g., 10).
For example:
ip arp inspection limit rate 10- Save the Configuration:
After configuring DAI, save the configuration:
write memoryor
copy running-config startup-configThis ensures that your DAI settings persist after a reboot.
- Verify DAI Configuration:
Use the following command to verify the DAI configuration:
show ip arp inspection interfacesThis command displays information about interfaces and their DAI settings.
Remember to adapt the commands to your specific network setup and requirements. DAI provides an additional layer of security against ARP-based attacks. Always be cautious when making changes to a network device’s configuration, especially if it’s in a production environment.