views:

209

answers:

3

I have a project to do which is packet monitoring. I want to capture each packet receive by specified network interface.

I want to know what I should start with to do my project .... should I learn socket programming first or what? should I learn how to use winpcap under C# or just do my own function.

please advice me from where I should start!!!

I know there are many code in C# out there in the internet for this but I want to learn it by myself but I do not know from where to star!

+3  A: 

You sould definitely learn the basics of socket programming first so you understand a little bit about what's going on. Next, I would look into programming using WinPCap, which is a packet capturing library. It's not built directly for .NET but there are, I believe, .NET wrappers or if nothing else you could call the functions by using COM Interop.

BobbyShaftoe
+2  A: 

I agree using WinPcap is probably a good idea. Specifically, look at SharpPcap. it is actively maintained. In fact, there was a release today.

Matthew Flaschen
+1  A: 

I recommend using Pcap.Net.

It is a very active .NET wrapper for WinPcap wrapper with a vast packet interpretation library. It has great quality and performance.

brickner