misc: small fix or general refactoring i did not bother commenting

This commit is contained in:
evilsocket 2018-02-20 04:28:12 +01:00
commit 3bcbbefe96
2 changed files with 2 additions and 1 deletions

View file

@ -150,7 +150,7 @@ func (lan *LAN) shouldIgnore(ip, mac string) bool {
return true
}
// skip broadcast addresses
if strings.HasSuffix(ip, ".255") {
if strings.HasSuffix(ip, BroadcastSuffix) {
return true
}
// skip broadcast macs

View file

@ -12,6 +12,7 @@ import (
const (
MonitorModeAddress = "0.0.0.0"
BroadcastSuffix = ".255"
BroadcastMac = "ff:ff:ff:ff:ff:ff"
IPv4MulticastStart = "01:00:5e:00:00:00"
IPv4MulticastEnd = "01:00:5e:7f:ff:ff"