Skip to content

Instantly share code, notes, and snippets.

@farhaven
Created April 3, 2019 18:29
Show Gist options
  • Save farhaven/08791401ec26b295aa27d325a297371a to your computer and use it in GitHub Desktop.
Save farhaven/08791401ec26b295aa27d325a297371a to your computer and use it in GitHub Desktop.
from __future__ import print_function, unicode_literals
import time
from scapy.all import ARP, Ether, sendp
def create_ARP(mac='f0:fe:6b:1e:4b:27', ip_addr='10.10.100.254'):
BCAST = ':'.join(['ff'] * 6)
print("Bcast", BCAST)
arp = ARP(psrc=ip_addr,
hwsrc=mac,
pdst=ip_addr)
return Ether(dst=BCAST) / arp
while True:
arp = create_ARP()
sendp(arp)
print(".")
time.sleep(1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment