Simple network loop detector based on idea here: https://blogs.cisco.com/networking/preventing-network-loops-a-feature-you-need-to-be-aware-of
Tested on debian12 linux.
git clone <url> netloop-detector
cd netloop-detector
make./netloop-detector <iface> <timeout_sec>./netloop-detector any 5- A veth pair and a bridge interface will be created.
- Both ends of the veth pair will be added to the created bridge.
- tcpdump will be started on the bridge to capture traffic.
- netloop-detector will run and attempt to detect loops.
- The veth pair and the bridge will be removed after the test.
- The first 10 entries in the resulting PCAP file will be displayed.
make test