modifications for private IP and IPv6