tweak client to handle ipv4 and ipv6