Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

.net packet capture: pcap.net vs sharppcap

interested in any comments anyone has around the various .net tools which can be used for passive packet capture. In terms of winpcap the choice seems to be between pcap.net and sharppcap. Another potential offering is Microsoft's NetworkMonitor and I am sure there are others as well.

I have used ethereal/wireshark as a diagnostic tool occasionally over the years but that is the limit of my knowledge. I'm looking to automate the capture process and subsequent diagnostic processing. I am tending towards pcap.net at the moment but would like to hear from anyone who has used two or more of these tools and whether they'd recommend one over another. My preference would be for the simplest interface/shallowest learning curve. Please let me know your thoughts.

Thanks Patrick

like image 640
Patrick Avatar asked Apr 05 '11 23:04

Patrick


People also ask

What is SharpPcap?

SharpPcap is a cross-platform(Windows, Mac, Linux) packet capture framework for the . NET environment. It provides an API for capturing, injecting, analyzing and building packets using any . NET language such as C# and VB.NET. Product.

Which of the following is used for capturing packets event engine event handler TCP handler libpcap?

Zeek uses the standard libpcap library for capturing packets to be used in network monitoring and analysis.

What data is captured in a PCAP file?

What is a PCAP file? PCAP files are data files created using a program. These files contain packet data of a network and are used to analyze the network characteristics. They also contribute to controlling the network traffic and determining network status.


2 Answers

Well, I've ended up using sharppcap because the dll references required for pcap.net wouldn't load into my project correctly. Expect it was my mistake but the sharppcap reference worked without fuss...

like image 42
Patrick Avatar answered Sep 18 '22 05:09

Patrick


If you're willing to use .NET 4 or willing to use older versions of Pcap.Net, it is definitely the choice. Pcap.Net is much more flexible and include many more features and is very easy to use.

Disclosure: I'm a developer in Pcap.Net.

like image 154
brickner Avatar answered Sep 21 '22 05:09

brickner