I'm using visual studio to try to run this code (the code from the link you 
said) and first it says, 
"Error    1    fatal error C1083: Cannot open include file: 'pcap.h': No such 
file or directory"
even after adding existing item and browsing to it. So, I add new item, copy 
the contents of pcap.h into it, and save it as pcap.h. next error,
"Error    1    fatal error C1083: Cannot open include file: 'pcap-stdinc.h': No 
such file or directory"
I try repeating the last step, but it never works.

At one point I had tried to run their "example" solutions, with about 13 errors 
about 
"Error    1    error C3163: '_vsnprintf': attributes inconsistent with previous 
declaration"

Also, that is NOT a tutorial. They don't tell you what you need to actually 
execute the code, i.e. which .h files are needed to be included (other then the 
#include), whether it only needs the .dll or what. It's very frustrating trying 
to run code with all the provided information, only to discover that there's 
still vital information not given.

I'm not sure if anyone here is familiar with several programs written for use 
with the game Warcraft III, namely banlist and listchecker. These programs scan 
through the traffic to your computer and log several bits of information about 
players you interact with, ultimately allowing you to compile a list of players 
you do not wish to have interaction with again. Also, they have built in ping 
functionality, as well as several other helpful tools. The problem is that they 
each have strengths, but definate weaknesses, and who wants to run 4 programs 
in tandem with a game to do everything if they can just combine them. I've 
determined that their functionality stems from winpcap, and wanted to write my 
own version of these programs that incorporates their strengths into 1 package. 
I don't like c++ or c, and wanted to do it in c#. I had no idea (as it said 
nothing about it) that this wasn't really set up to be used with .net straight 
away (as there are no
 .sln's that just compile and work properly) and wanted to know if I needed to 
compile something into a .dll or if there was just an updated c# version out 
there.

 Benjamin C. Kiefer


----------------------------------------------------------------------

Message: 1
Date: Wed, 22 Jul 2009 16:43:56 -0700 (PDT)
From: Benjamin Kiefer <[email protected]>
Subject: [Winpcap-users] Out of my depth...
To: [email protected]
Message-ID: <[email protected]>
Content-Type: text/plain; charset="us-ascii"

Okay, I'm a college student who barely uses c++, and wanted to put all the 
functionality of winpcap into a .dll that I can use in, say, c#. Would anyone 
be able to tell me what exactly I'd need for it to work, because I'm REALLY 
confused by the documentation. The sample code doesn't compile properly, and 
it'd be really nice to just have a .sln to run that actually works. This seems 
very complex as is, and the documentation doesn't really help. Apparently they 
don't know what "tutorials" look like, because as far as I know, giving someone 
a complete .cpp and barely going into what is done on it doesn't help anyone 
learn.

Any help would be greatly appreciated (i.e. a REAL tutorial describing which 
functions are used to do what and why, and how they do it) or I'd just be happy 
with a .dll that I can call stuff from if that's all you can do. Thanks again.

Benjamin C. Kiefer



      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: 
http://www.winpcap.org/pipermail/winpcap-users/attachments/20090722/04b3892d/attachment-0001.htm
 

------------------------------

Message: 2
Date: Wed, 22 Jul 2009 17:37:26 -0700
From: "Gianluca Varenni" <[email protected]>
Subject: Re: [Winpcap-users] Out of my depth...
To: <[email protected]>
Message-ID: <11c64035aa734ba88269ec9644577...@nelson3>
Content-Type: text/plain; charset="iso-8859-1"


  ----- Original Message ----- 
  From: Benjamin Kiefer 
  To: [email protected] 
  Sent: Wednesday, July 22, 2009 4:43 PM
  Subject: [Winpcap-users] Out of my depth...


  Okay, I'm a college student who barely uses c++, and wanted to put all the 
functionality of winpcap into a .dll that I can use in, say, c#. Would anyone 
be able to tell me what exactly I'd need for it to work, because I'm REALLY 
confused by the documentation. The sample code doesn't compile properly, and 
it'd be really nice to just have a .sln to run 

Which samples in the developer's pack do not compile? Can you be a bit more 
specific?


  that actually works. This seems very complex as is, and the documentation 
doesn't really help. Apparently they don't know what "tutorials" look like, 
because as far as I know, giving someone a complete .cpp and barely going into 
what is done on it doesn't help anyone learn.

Have you looked at the tutorial here

http://www.winpcap.org/docs/docs_41b5/html/group__wpcap__tut.html
?

Also, there are a bunch of .NET wrappers for WinPcap, at least one is available 
on codeproject (just search for "net wrapper on google").

Have a nice day
GV

  Any help would be greatly appreciated (i.e. a REAL tutorial describing which 
functions are used to do what and why, and how they do it) or I'd just be happy 
with a .dll that I can call stuff from if that's all you can do. Thanks again.


  Benjamin C. Kiefer






------------------------------------------------------------------------------


  _______________________________________________
  Winpcap-users mailing list
  [email protected]
  https://www.winpcap.org/mailman/listinfo/winpcap-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: 
http://www.winpcap.org/pipermail/winpcap-users/attachments/20090722/7edc3dda/attachment-0001.htm
 

------------------------------

Message: 3
Date: Wed, 22 Jul 2009 18:05:42 -0700
From: Guy Harris <[email protected]>
Subject: Re: [Winpcap-users] Out of my depth...
To: [email protected]
Message-ID: <[email protected]>
Content-Type: text/plain; charset=WINDOWS-1252; format=flowed;
    delsp=yes


On Jul 22, 2009, at 4:43 PM, Benjamin Kiefer wrote:

> Okay, I'm a college student who barely uses c++, and wanted to put  
> all the functionality of winpcap into a .dll that I can use in, say,  
> c#.

Is the goal to write such an encapsulation, or is the goal to use  
WinPcap from C#?

If the goal is the latter - i.e., if you're not, for example, trying  
to learn how to wrap C/C++ libraries for use in .NET - then the  
Wikipedia page for pcap (libpcap/WinPcap):

    http://en.wikipedia.org/wiki/Pcap

says:

    Wrappers for use of libpcap/WinPcap in languages other than C and C++

        ...

        ? WinPcapNET and SharpPcap, .NET wrappers for WinPcap

and SharpPcap is at

    http://sharppcap.wiki.sourceforge.net/

(WinPcapNet is at

    http://blogs.creadev.net/benj/2007/03/26/winpcapnet-first-release/

but I don't know whether anything's been done on it since then;  
SharpPcap's last release was in May of this year, so it appears to be  
active.)



      
_______________________________________________
Winpcap-users mailing list
[email protected]
https://www.winpcap.org/mailman/listinfo/winpcap-users

Reply via email to