remove surrounding "[]" of IPv6 address