Detect local hosts on both ends