PDA

Click to See Complete Forum and Search --> : VB - A Simple Portscanner


plenderj
Feb 18th, 2003, 12:56 PM
Attached is a simple implementation of a port scanner.
It uses the Winsock control, and gives the option of how many threads to use for scanning at any one time.

Simple Port Scanner.zip (http://www.vbforums.com/attachment.php?s=&postid=1059401)

LITHIA
Jul 17th, 2003, 12:54 PM
Cool project well done plenderj

I like the way you have set out your code, looks very neat and almost c++ like heh

Keep up the good work, this should be a good example!

Only improvments I could say, is to increase the Refresh Rate of the label which shows which port is currently being scanned. I have seen other examples (EXE form) that refresh at each port chnage, not sure how much resources that would take though...

Thanks again

Electroman
Jul 28th, 2003, 01:18 PM
Originally posted by LITHIA
Only improvments I could say, is to increase the Refresh Rate of the label which shows which port is currently being scanned. I have seen other examples (EXE form) that refresh at each port chnage, not sure how much resources that would take though When port scanners refresh on ever port thats normally because they're only scanning using 1 thread if I remember correctly. And if you scan with 5 threads your label will do this: 0,5,10,15,20,...
Its because the threads is how many ports to scan at a time.

BShadow
Aug 27th, 2003, 08:45 PM
Originally posted by plenderj
Attached is a simple implementation of a port scanner.
It uses the Winsock control, and gives the option of how many threads to use for scanning at any one time.

Simple Port Scanner.zip (http://www.vbforums.com/attachment.php?s=&postid=1059401)

Very nice project. I'm working on a similar project myself. I've created ActiveX Exe multithreading objects to boost up some speed. I've used the Winsock class (forgot where I found that one) for Winsock, because it's laks the MS Winsock control bugs. Because it uses API to access Windows Winsock, I had to create the ActiveX EXE threading.

Now, my scanner uses a time-out mechanism to make sure the app doesn't hang when a .connect() is not accepted because the port doesn't exist. This is the most time consuming of the whole scanning. How can this be made more efficient?

plenderj
Oct 21st, 2004, 09:51 AM
* 21-October-2004 - Moved to CodeBank *