I'm writing a deauth attacker python script to kick everyone from an AP but my own devices (pretty much reverse engineered DanMcInerney's wifi jammer). It works fine so far, but every time scapy captures client macs it also captures devices that are connected to another AP or not connected at all. I tried fixing the mon0 channel with sudo airmon-ng start mon0 11 but it's not working...
here's the code that gets the mac addresses:
def sniffmgmt(p):
stamgmtstypes = (0, 2, 4)
if p.haslayer(Dot11):
if p.type == 0 and p.subtype in stamgmtstypes:
if p.addr2 not in CliList:
print p.addr2
CliList.append(p.addr2)
sniff(iface=moniface, prn=sniffmgmt, timeout = scantime)
I could't find a proper documentation for scapy and I'm new to networking... so any help is apreciated.
Thanks in advance !