Add device for ARP requests, too

This commit is contained in:
maride 2019-11-28 13:51:00 +01:00
parent e363a5929d
commit e41a957e8d

View File

@ -34,6 +34,9 @@ func ProcessARPPacket(packet gopacket.Packet) error {
// Request packet
participant.asked++
appendIfUnique(net.IP(arppacket.DstProtAddress).String(), participant.askedList)
// Add device entry
addDeviceEntry(sourceAddr, net.IP(arppacket.SourceProtAddress).String())
} else {
// Response packet
participant.answered++