Monitoring of outgoing internet traffic
Is there a way to track internet traffic programmatically? I would like to register the pages that users visit on the Internet. Is it possible to do this with .NET code, there is a third party .NET component that can be used to get the data.
The internet traffic information needs to be stored in the database, so I can't use a plugin or something for IE. We also want to include this code in our existing product so that we cannot use a third party product that cannot be redistributed.
It would be great if this thing could monitor traffic for all browsers, but monitoring IE traffic might be sufficient as well.
Sniffer customization is possible through WinPCap library in which several projects complete it .NET:
- http://geekswithblogs.net/dotnetnomad/archive/2008/01/31/119140.aspx
- http://www.codeproject.com/KB/IP/dotnetwinpcap.aspx
- http://coolthingoftheday.blogspot.com/2006/02/sharppcap-net-winpcap-wrapper.html
and probably some others as well as a Googling question.
a source to share
You will need to create some software that will act as a proxy. You should start by exploring programs like "Fiddler" to understand the concepts and what you need to implement.
If you want my professional opionon you should go to Server Fault and ask for opionons for an inexpensive internet proxy solution. Writing this stuff on its own while challenging and fun won't make good business sense.
a source to share
If you want to monitor all traffic from all users on your network, consider a product like Microsoft Internet Security and Acceleration Server (ISA)
While this is probably too large for what you want, the important thing is that you want all traffic to go through one point (proxy) where traffic can be logged. Since all traffic goes through this point, users cannot escape detection with an alternative browser, etc.
a source to share
As JD mentioned , you should look into Fiddler.With this proxy you can monitor all web traffic (if your browser is configured to use a script as a proxy).
If you don't want fiddler as a standalone application and need its functionality in your own application, you should take a look at FiddlerCore . This is a .Net assembly that encapsulates the core functionality of Fiddler.
If you need a more crude way to sniff data (you may not want [or cannot] configure client proxies) Vinko's answer will help you further.
a source to share