PDA

View Full Version : Need a port scanner in Batch



Raz3r
12-03-2005, 06:04 PM
Hi,
I'm writting a program in batch and I wanted to write a port scanner.
I haven't had any luck, and I'm going crazy because I have been trying for days to make it... :confused: I have tryed serching Google but I come up with nothing.
I understand that SyntaX****** knows a lot of Batch and I really need help on this one.

I just want to know if its even possible to write a port scanner in Batch? And if it is, could someone paste the code here so I can view it and try to see what I was doing wrong?

Thx a lot for your answers! :D

Ezekiel
12-04-2005, 05:31 AM
You can't "write a program" in batch, because batch isn't actually a programming language, it's just a series of comands to be executed by the command interpreter. You could only use commands already available to you in cmd, so you wouldn't get very far making a port scanner out of ms-dos commands. If you really wanted to use batch, you could probably use telnet in your script to connect to every single port available, but it would be too slow to be a useful port scanner.

Raz3r
12-04-2005, 08:10 AM
I know that Batch is just a script file filled with DOS commands... Therefore its not a programming language. But I want to learn as much of DOS as possible before I go and learn Python or maybe even Perl.

So if anyone has any ideas of how a Telnet port scanner code would look like, please post it.
Thx. :)

SyntaXmasteR
12-05-2005, 12:54 PM
Add nmap to your system*2 folder and incorporate this into your script ~