diff --git a/.listener.go.kate-swp b/.listener.go.kate-swp new file mode 100644 index 0000000..f82d04e Binary files /dev/null and b/.listener.go.kate-swp differ diff --git a/utils.go b/utils.go index 3ce2133..b7f064c 100644 --- a/utils.go +++ b/utils.go @@ -18,3 +18,13 @@ func generateRandomMAC() net.HardwareAddr { return mac } + +// Check if IP address is all zero. +func isZeroAddr(ip net.IP) bool { + for _, b := range ip { + if b != 0x0 { + return false + } + } + return true +}