Made ip a HostName instead of a String.