I work at a datacenter and work on servers in various global locations. We have about 10 proxy servers and no good way to know which proxy server to use on which server/domain/vlan ect... Don't ask why as I have and have been told "go ask security". Anyhow I wanted to use a batch script to telnet to each proxy server on port 8080. I have the proxy server's IP addresses and know they're listening on 8080. How could I from a script check one by one and come back with a response?
Hope this makes sense. At this time I have to go into internet settings -> connection -> proxies and try one by one. And these are windows 03 & 08 servers.
Any help is greatly appreciated!
To clarify. I'm looking for a script that will go through a list of known proxies and ports and verify connectivity.
Got the following error with the powershell script
I would use some other command line tool like wget instead. These will be much more easily batched. wget is not designed to make requests directly to proxies, but you'll still get a response from the proxy (probably a 502 or something) which is all you need given your requirements.
You'll get some kind of HTTP response out of the ones that are responding and a connection timeout for the ones that aren't.
EDIT:
Here's something using Powershell:
Using that you'll get some kind of HTTP response out of the proxies that are listening, a connection timeout, or host not found / name resolution error.
Configure proxy.pac on your clients. Look at this link will explain how to set it up. http://en.wikipedia.org/wiki/Proxy_auto-config
HTH