set up get_host() and get_port()