made port numbers and host addresses more dynamic