HighwayGlider Posted December 16, 2014 Share Posted December 16, 2014 Hi, My problem is quite simple but I don't know if the solution will be simple. I have text file (portlist.txt) in the following format: NAT IP Address Ports xx.xx.xx.xx 23 xx.xx.xx.xx 23 xx.xx.xx.xx 23 I want to know if the ports are open by telnet. And I want to output the result in a text file in the following format: xx.xx.xx.xx OK xx.xx.xx.aa KO Is it possible to create a batch that will do the job? I know it can be done manually but I have around 106 servers to test. Thanks. Link to comment Share on other sites More sharing options...
+John Teacake MVC Posted December 16, 2014 MVC Share Posted December 16, 2014 Yeah I tried something like this years ago and its tricky. I ended up witing a VB program to emulate the keyboard input but it was flaky at best. Link to comment Share on other sites More sharing options...
sc302 Veteran Posted December 16, 2014 Veteran Share Posted December 16, 2014 angryip can scan open ports, you can save the output to a text file. You can scan an entire class c in a few minutes, if all you are trying to do is see if a port is open or not. A few seconds if you are trying to see what you have that can respond on that network. http://angryip.org/ Link to comment Share on other sites More sharing options...
+BudMan MVC Posted December 16, 2014 MVC Share Posted December 16, 2014 Another option would be nmap, you can scan a list of IPs, ports you want to check and it spits out the output for each IP. Here is a nice gui for windows and nmap. http://nmap.org/zenmap/ Praetor 1 Share Link to comment Share on other sites More sharing options...
Praetor Posted December 16, 2014 Share Posted December 16, 2014 1+ for Nmap. Link to comment Share on other sites More sharing options...
+John Teacake MVC Posted December 18, 2014 MVC Share Posted December 18, 2014 Oh its more simple than I read, I thought you meant like connect to a list of IP's and issue some commands by telnet. Yeah loads can do this. Nirsoft Tools are good, NMap, Netscanner from Softperfect. etc etc etc etc etc etc etc Angry IP etc etc haha. Link to comment Share on other sites More sharing options...
vcfan Posted December 18, 2014 Share Posted December 18, 2014 Oh its more simple than I read, I thought you meant like connect to a list of IP's and issue some commands by telnet. Yeah loads can do this. Nirsoft Tools are good, NMap, Netscanner from Softperfect. etc etc etc etc etc etc etc Angry IP etc etc haha. i had this problem in the past. the solution was to use plink http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html and this is the command to connect to an IP and issue commands from a text file. if multiple IPs, just put it in a batch file plink.exe "ip address here" -P "port number here" -telnet < "text file name with commands here,so input.txt" +John Teacake 1 Share Link to comment Share on other sites More sharing options...
+John Teacake MVC Posted December 18, 2014 MVC Share Posted December 18, 2014 Interesting!! Thanks! Link to comment Share on other sites More sharing options...
Recommended Posts