Avoiding eternal loop by checking if Proxy endpoint is actually local one