Why is the IP address of the Google DNS server the only one, which is returning open ports in my case?
I am creating a port scanner of a selected IP address, for my Android app. I use Runtime.getRuntime().exec("nc [host] [port]") to scan ports. My scanner only tests the top 100 ports, separately for TCP and UDP. Depending on the code for this process, I consider the port open or closed ("0" means the process was successful, so the port is open, any other number means failure).
override fun run() {
val response: String
val runtime = Runtime.getRuntime()
val...