Closed nuald closed 3 years ago
the SDK could really use an update. The batch file currently throws a few errors during packaging as some header files aren't there or where they used to be.
Thanks for the detailed report. I've regenerated the SDK, which hadn't been done since before we updated libpcap to 1.8.1. We may need to regenerate again soon after doing some cleanup, but could you check whether Npcap SDK 0.1 fixes your specific problem?
Thanks @dmiller-nmap Could you then please also look into updating the examples? They currently only work if npcap is install in "wpcap compatibility mode".
Hi @sgeto,
Those examples are still for WinPcap. For how to support Npcap native mode
, you can see our docs here: https://rawgit.com/nmap/npcap/master/docs/npcap-guide-wrapper.html#npcap-feature-native
There is also a WinDump example for Npcap here: https://github.com/hsluoyz/windump
A delay-loaded DLL! I see. Thanks a lot
Python 2.7 C extensions use Visual Studio 2008 compiler (https://www.microsoft.com/en-us/download/details.aspx?id=44266) that is not compatible with the SDK, giving the error:
The problem is within the pcap-stdinc.h header file - it has
#if _MSC_VER < 1900
check that redefinesvsnprintf
for CL < 19 (VS2008 uses CL 15). Please note that the original WinPcap SDK has a different condition.Steps To Reproduce
cd npcap-sdk\Examples-pcap\basic_dump
cl basic_dump.c /I ..\..\Include\ /DWIN32 ..\..\Lib\x64\wpcap.lib
Please note that if you install and use Visual Studion 2017 (CL 19), no errors are produced and it compiles the correct exe file.
Proposed Solution
Please note that current libpcap doesn't contain the aforementioned check and it's possible that just rebuilding SDK would be enough to eliminate the problem.