refactor find_node_ip_in_network